esc esc - 1 year ago 112
Linux Question

How does pip decide which many linux wheel to use?

Binary many-linux wheels are now supported:

Specifically I would like to install the many linux wheel for scipy on Travis, using the trusty beta operating system. The wheels are listed here:

I get:

Collecting scipy
Downloading scipy-0.17.1.tar.gz (12.4MB)
100% |████████████████████████████████| 12.4MB 100kB/s

Instead of:

Collecting scipy
Downloading scipy-0.17.1-cp27-cp27mu-manylinux1_x86_64.whl (39.5MB)
100% |████████████████████████████████| 39.5MB 37kB/s

So, in order to fix this, I would like to know, how pip determines which wheel to download and install. And yes, I did update pip to version 8.1.2 which supports binary many linux wheels.

Specifically, I am not interested in alternative solutions, just answer the question, if you can.

Answer Source

You need pip 8.1 or later and a linux distribution that is based on glibc (and not musl libc as alpine linux for instance).

EDIT: the function pip.pep425tags.get_supported() should return the list of supported platform tags.

Also may I kindly suggest you to use python 3.5 instead of 2.7 ;)