Could not find a version that satisfies the requirement <package>

Gabriel

I'm installing several Python packages in Ubuntu 12.04 using the following requirements.txt file:

numpy>=1.8.2,<2.0.0
matplotlib>=1.3.1,<2.0.0
scipy>=0.14.0,<1.0.0
astroML>=0.2,<1.0
scikit-learn>=0.14.1,<1.0.0
rpy2>=2.4.3,<3.0.0

and these two commands:

$ pip install --download=/tmp -r requirements.txt
$ pip install --user --no-index --find-links=/tmp -r requirements.txt

(the first one downloads the packages and the second one installs them).

The process is frequently stopped with the error:

  Could not find a version that satisfies the requirement <package> (from matplotlib<2.0.0,>=1.3.1->-r requirements.txt (line 2)) (from versions: )
No matching distribution found for <package> (from matplotlib<2.0.0,>=1.3.1->-r requirements.txt (line 2))

which I fix manually with:

pip install --user <package>

and then run the second pip install command again.

But that only works for that particular package. When I run the second pip install command again, the process is stopped now complaining about another required package and I need to repeat the process again, ie: install the new required package manually (with the command above) and then run the second pip install command.

So far I've had to manually install six, pytz, nose, and now it's complaining about needing mock.

Is there a way to tell pip to automatically install all needed dependencies so I don't have to do it manually one by one?

Add: This only happens in Ubuntu 12.04 BTW. In Ubuntu 14.04 the pip install commands applied on the requirements.txt file work without issues.

Simeon Visser

This approach (having all dependencies in a directory and not downloading from an index) only works when the directory contains all packages. The directory should therefore contain all dependencies but also all packages that those dependencies depend on (e.g., six, pytz etc).

You should therefore manually include these in requirements.txt (so that the first step downloads them explicitly) or you should install all packages using PyPI and then pip freeze > requirements.txt to store the list of all packages needed.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Java

'pip install' fails for every package ("Could not find a version that satisfies the requirement")

From Dev

'pip install' fails for every package ("Could not find a version that satisfies the requirement")

From Java

Could not find a version that satisfies the requirement tensorflow

From Dev

Could not find a version that satisfies the requirement in python

From Dev

Could not find a version that satisfies the requirement tensorflow

From Dev

Could not find a version that satisfies the requirement djangocms

From Dev

OSX Brew Python "Could not find a version that satisfies the requirement pyopencv"

From Java

ERROR: Could not find a version that satisfies the requirement csv (from versions: none)

From Dev

Error : Could not find a version that satisfies the requirement webdriver (from versions: )

From Dev

pip could not find a version that satisfies the requirement django==2.2.1

From Dev

docker ERROR: Could not find a version that satisfies the requirement apturl==0.5.2

From Dev

OSX Brew Python "Could not find a version that satisfies the requirement pyopencv"

From Dev

How to fix install error "Could not find a version that satisfies the requirement pyplot"?

From Dev

Could not find version that satisfies requirement in buildozer.spec file

From Dev

Pip "Could not find a that satisfies the requirement"

From Java

ERROR: Could not find a version that satisfies the requirement dask-cudf (from versions: none)

From Dev

PIP randomly fails 'Could not find a version that satisfies the requirement' with the same requirements.txt

From Dev

Pip install-couldn't find a version that satisfies the requirement

From Dev

Time module: Couldn't find a version that satisfies the requirement

From Dev

Could not find a configuration file for package "ECM" that is compatible with requested version 1.5.0

From Dev

Could not find any downloads that satisfy the requirement dateutil

From Dev

Yum installs wrong version of package with range requirement

From Dev

Could not find package gdebi

From Dev

Unable to add Laravel package Intervention Image - Requirement could not be met

From Dev

Unable to add Laravel package Intervention Image - Requirement could not be met

From Dev

Is there a way to programmatically confirm that a python package version satisfies a requirements specifier?

From Dev

PIP Could not find any downloads that satisfy the requirement SQLAlchemy

From Dev

Could not find any downloads that satisfy the requirement django-1.6.1

From Dev

Could not find any downloads that satisfy the requirement mysql-connector-python

Related Related

  1. 1

    'pip install' fails for every package ("Could not find a version that satisfies the requirement")

  2. 2

    'pip install' fails for every package ("Could not find a version that satisfies the requirement")

  3. 3

    Could not find a version that satisfies the requirement tensorflow

  4. 4

    Could not find a version that satisfies the requirement in python

  5. 5

    Could not find a version that satisfies the requirement tensorflow

  6. 6

    Could not find a version that satisfies the requirement djangocms

  7. 7

    OSX Brew Python "Could not find a version that satisfies the requirement pyopencv"

  8. 8

    ERROR: Could not find a version that satisfies the requirement csv (from versions: none)

  9. 9

    Error : Could not find a version that satisfies the requirement webdriver (from versions: )

  10. 10

    pip could not find a version that satisfies the requirement django==2.2.1

  11. 11

    docker ERROR: Could not find a version that satisfies the requirement apturl==0.5.2

  12. 12

    OSX Brew Python "Could not find a version that satisfies the requirement pyopencv"

  13. 13

    How to fix install error "Could not find a version that satisfies the requirement pyplot"?

  14. 14

    Could not find version that satisfies requirement in buildozer.spec file

  15. 15

    Pip "Could not find a that satisfies the requirement"

  16. 16

    ERROR: Could not find a version that satisfies the requirement dask-cudf (from versions: none)

  17. 17

    PIP randomly fails 'Could not find a version that satisfies the requirement' with the same requirements.txt

  18. 18

    Pip install-couldn't find a version that satisfies the requirement

  19. 19

    Time module: Couldn't find a version that satisfies the requirement

  20. 20

    Could not find a configuration file for package "ECM" that is compatible with requested version 1.5.0

  21. 21

    Could not find any downloads that satisfy the requirement dateutil

  22. 22

    Yum installs wrong version of package with range requirement

  23. 23

    Could not find package gdebi

  24. 24

    Unable to add Laravel package Intervention Image - Requirement could not be met

  25. 25

    Unable to add Laravel package Intervention Image - Requirement could not be met

  26. 26

    Is there a way to programmatically confirm that a python package version satisfies a requirements specifier?

  27. 27

    PIP Could not find any downloads that satisfy the requirement SQLAlchemy

  28. 28

    Could not find any downloads that satisfy the requirement django-1.6.1

  29. 29

    Could not find any downloads that satisfy the requirement mysql-connector-python

HotTag

Archive