Analyze pip install ERROR: Could not find a version that satisfies the requirement (original) (raw)

June 5, 2024, 11:30am 1

I have a requirement file, and try to install it by:
pip install -r requirement .txt

It fails on a specific package with this error: ERROR: Could not find a version that satisfies the requirement

I know the package does exist, in the correct index, so I guess it points on a version conflict.
However, I don’t know how can I analyze it. I tried with pipdeptree, but it lisst the deps for the already installed packages, not for the problematic package.

I’ll appreciate any idea, how can I solve it.

thanks!

Can you show the error that you are getting?

yaelperl1234 (Yaelperl1234) June 5, 2024, 11:51am 3

ERROR: Could not find a version that satisfies the requirement <package_name> (from versions: none)
ERROR: No matching distribution found for <package_name>

Can you provide a screenshot?

yaelperl1234 (Yaelperl1234) June 5, 2024, 11:55am 5

unfortunately not (security policy of my company…)

To be honest, I have never seen someone attempting to install a text file using pip install which is what you are implying with the following:

But if you are missing a required package, you generally install it via the following command in the command prompt.

pip install package_name_here

kknechtel (Karl Knechtel) June 6, 2024, 6:04am 7

No, that isn’t what’s happening there. Please see the documentation for the -r option for Pip. It’s very common to do things this way:

Sorry to say, without knowing which package it is or what else is currently happening in your Python environment, it will be difficult to impossible to offer any meaningful help.

Rosuav (Chris Angelico) June 6, 2024, 6:37am 8

Are you sure that this is the command you are running? It would be more common to use:

pip install -r requirements.txt

Copy and paste what you are using, don’t retype it.

yaelperl1234 (Yaelperl1234) June 6, 2024, 7:41am 9

python3.7 -m pip install -r requirements.txt

the requirements.txt file looks like:

pandas>=1.1.5,<2
pyarrow>=2.0.0,<15.0.0
problematic_package

kknechtel (Karl Knechtel) June 6, 2024, 1:29pm 10

And to be clear, you can watch it installing Pandas and pyarrow successfully?

yaelperl1234 (Yaelperl1234) June 6, 2024, 2:04pm 11

yes, it installed them successfully.

Janco01 (Janco01)

January 13, 2025, 9:09am 12

I am running into the same issue.

Versions I use:

In my requirments.txt file i Have the following
splunk-sdk~=1.7.0

Command I use to run the pip install

python -m pip install --upgrade --platform manylinux2014_x86_64 --python-version 3.9 --only-binary=:all: -r requirments.txt --ignore-installed --target .

Here is the error I get:

Screenshot 2025-01-13 at 11.12.38 AM

Hope someone has some solution or info on why this is not working : )

abessman (Alexander Bessman) January 13, 2025, 10:07am 13

It’s because you specify --only-binary=:all:, but at least one of the packages in your requirements.txt, specifically splunk-sdk, does not provide a binary.

Try removing --only-binary=:all: from your command.

sabhya (sabhya)

January 24, 2025, 11:24am 14

I am also encountering the same problem while installing Netpyne using in conda3 environment. ubuntu 18.04.

image

can anyone help me i a am new to this not able to understand how does this work?

abessman (Alexander Bessman) January 24, 2025, 11:40am 15

You are using Python 2.7, which is 15 years old and went out of support five years ago. The Python ecosystem has long since moved on; you cannot expect to be able to pip install anything to such ancient software.

Upgrade to Python 3.

shre-afk (shre-afk) February 3, 2025, 10:24am 16

I am also facing similar issue, what to do resolve the issue?

abessman (Alexander Bessman) February 3, 2025, 10:29am 17

Open a new topic where you describe your issue in detail.

shre-afk (shre-afk) February 3, 2025, 10:50am 18

mikez (Michael)

April 11, 2025, 2:57pm 19

Go to pypi.org and lookup the package name that causes the error. Next, check what it says under “Meta” and “Requires”. For example, in the bpy package we see this:

image

That means you need to use python 3.11 to install this.

You can check which version of Python that pip is using by running:

pip --version