ERROR: No matching distribution found for ipython==7.17.0 - python

I uploaded a Python app to Heroku. In my requirements.txt file I have a line for ipython==7.17.0 but Heroku seems unable to retrieve it, I don't understand why this might happen because I'm able to download that ipython version on my machine.
The complete error thrown is:
ERROR: Could not find a version that satisfies the requirement ipython==7.17.0 (from -r /tmp/build_76afe907/requirements.txt (line 32)) (from versions: 0.10, 0.10.1, 0.10.2, 0.11, 0.12, 0.12.1, 0.13, 0.13.1, 0.13.2, 1.0.0, 1.1.0, 1.2.0, 1.2.1, 2.0.0, 2.1.0, 2.2.0, 2.3.0, 2.3.1, 2.4.0, 2.4.1, 3.0.0, 3.1.0, 3.2.0, 3.2.1, 3.2.2, 3.2.3, 4.0.0b1, 4.0.0, 4.0.1, 4.0.2, 4.0.3, 4.1.0rc1, 4.1.0rc2, 4.1.0, 4.1.1, 4.1.2, 4.2.0, 4.2.1, 5.0.0b1, 5.0.0b2, 5.0.0b3, 5.0.0b4, 5.0.0rc1, 5.0.0, 5.1.0, 5.2.0, 5.2.1, 5.2.2, 5.3.0, 5.4.0, 5.4.1, 5.5.0, 5.6.0, 5.7.0, 5.8.0, 5.9.0, 5.10.0, 6.0.0rc1, 6.0.0, 6.1.0, 6.2.0, 6.2.1, 6.3.0, 6.3.1, 6.4.0, 6.5.0, 7.0.0b1, 7.0.0rc1, 7.0.0, 7.0.1, 7.1.0, 7.1.1, 7.2.0, 7.3.0, 7.4.0, 7.5.0, 7.6.0, 7.6.1, 7.7.0, 7.8.0, 7.9.0, 7.10.0, 7.10.1, 7.10.2, 7.11.0, 7.11.1, 7.12.0, 7.13.0, 7.14.0, 7.15.0, 7.16.0, 7.16.1)
ERROR: No matching distribution found for ipython==7.17.0 (from -r /tmp/build_76afe907/requirements.txt (line 32))

The last allowed version is 7.16.1, that means you use Python 3.6.
7.17 requires Python 3.7+.

Related

Mac M1 - ERROR: Could not find a version that satisfies the requirement gevent==21.8.0

Trying to install gevent in virtual env from a requirements.txt using pip-sync but getting this error.
Collecting gevent==21.8.0
Using cached gevent-21.8.0.tar.gz (6.2 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... error
ERROR: Could not find a version that satisfies the requirement gevent==21.8.0 (from versions: 0.9.2, 0.9.3, 0.10.0, 0.11.0, 0.11.1, 0.11.2, 0.12.0, 0.12.1, 0.12.2, 0.13.0, 0.13.1, 0.13.2, 0.13.3, 0.13.4, 0.13.5, 0.13.6, 0.13.7, 0.13.8, 1.0, 1.0.1, 1.0.2, 1.1a1, 1.1a2, 1.1b1, 1.1b2, 1.1b3, 1.1b4, 1.1b5, 1.1b6, 1.1rc1, 1.1rc2, 1.1rc3, 1.1rc4, 1.1rc5, 1.1.0, 1.1.1, 1.1.2, 1.2a1, 1.2a2, 1.2.0, 1.2.1, 1.2.2, 1.3a1, 1.3a2, 1.3b1, 1.3b2, 1.3.0, 1.3.1, 1.3.2, 1.3.2.post0, 1.3.3, 1.3.4, 1.3.5, 1.3.6, 1.3.7, 1.4.0, 1.5a1, 1.5a2, 1.5a3, 1.5a4, 1.5.0, 20.4.0, 20.5.0, 20.5.1, 20.5.2, 20.6.0, 20.6.1, 20.6.2, 20.9.0, 20.12.0, 20.12.1, 21.1.0, 21.1.1, 21.1.2, 21.8.0, 21.12.0)
ERROR: No matching distribution found for gevent==21.8.0
Tried with:
pip/python version: 21.3.1/3.6.15, 22.2.2/3.8.13
Directly installing with pip install gevent==21.8.0
I suspect it has to do with the M1 chip as others not on the M1 were able to install with no issues.
I also don't get why the error states it can't find version 21.8.0 when that version is listed in the searched list within the ( ).

Could not find a version that satisfies the requirement Python

Could not find a version that satisfies the requirement librabbitmq==1.6.1 (from versions: 0.9.0, 0.9.1, 0.9.2, 0.9.3, 0.9.4, 0.9.5, 0.9.6, 0.9.7, 0.9.8, 0.9.9, 1.0.0, 1.0.1, 1.0.2, 1.0.3, 1.5.0, 1.5.1, 1.5.2, 1.6.0, 1.6.1, 2.0.0)
I am getting similar error while install librarabbitmq,numpy,supervisor,xattr,MySQL-python there are specific versions i am trying to install and it pops out the same error while the version remain in the packages it can't find those.
The command used to install the package
pip install librabbitmq==1.6.1
the same goes for other packages as well

ERROR: No matching distribution found for transformers==4.20.1

I am trying to install this specific version of transformers but I get the error:
pip3 install transformers==4.20.1
ERROR: Could not find a version that satisfies the requirement transformers==4.20.1
from versions: 0.1, 2.0.0, 2.1.0, 2.1.1, 2.2.0, 2.2.1, 2.2.2, 2.3.0, 2.4.0, 2.4.1,
2.5.0, 2.5.1, 2.6.0, 2.7.0, 2.8.0, 2.9.0, 2.9.1, 2.10.0, 2.11.0, 3.0.0, 3.0.1, 3.0.2,
3.1.0, 3.2.0, 3.3.0, 3.3.1, 3.4.0, 3.5.0, 3.5.1, 4.0.0rc1, 4.0.0, 4.0.1, 4.1.0,
4.1.1, 4.2.0, 4.2.1, 4.2.2, 4.3.0rc1, 4.3.0, 4.3.1, 4.3.2, 4.3.3, 4.4.0, 4.4.1,
4.4.2, 4.5.0, 4.5.1, 4.6.0, 4.6.1, 4.7.0, 4.8.0, 4.8.1, 4.8.2, 4.9.0, 4.9.1, 4.9.2,
4.10.0, 4.10.1, 4.10.2, 4.10.3, 4.11.0, 4.11.1, 4.11.2, 4.11.3, 4.12.0, 4.12.1,
4.12.2, 4.12.3, 4.12.4, 4.12.5, 4.13.0, 4.14.0, 4.14.1, 4.15.0, 4.16.0, 4.16.1,
4.16.2, 4.17.0, 4.18.0)
ERROR: No matching distribution found for transformers==4.20.1
I know the version exists since I have it installed on my local machine. I installing the package on an ubuntu remote machine. The Python version is 3.6.9. How can I get the version I need if it's saying that it doesn't even exist.
The 4.20.1 build does not support Python prior to 3.7. You'll either need to pick an earlier version or upgrade your Python.
You need Python >=3.7. You might also want to upgrade pip:
pip install --upgrade pip
https://pypi.org/project/transformers/4.20.0/

How to include a release candidate (rc) OR the actual version once released in `requirements.txt`

I want to set a dependency in my requirements.txt for tensorflow~=2.5.0. At the time of writing, tensorflow==2.5.0 hasn't been released yet. The latest version available is the release candidate tensorflow==2.5.0rc3. How can I succinctly tell pip to "install the most recent tensorflow 2.5.x version, including release candidates"?
What I've tried so far:
tensorflow~=2.5.0
ERROR: Could not find a version that satisfies the requirement tensorflow~=2.5.0 (from versions: 2.5.0rc0, 2.5.0rc1, 2.5.0rc2, 2.5.0rc3)
ERROR: No matching distribution found for tensorflow~=2.5.0
tensorflow>2.4.1
ERROR: Could not find a version that satisfies the requirement tensorflow>2.4.1 (from versions: 1.13.0rc1, 1.13.0rc2, 1.13.1, 1.13.2, 1.14.0rc0, 1.14.0rc1, 1.14.0, 1.15.0rc0, 1.15.0rc1, 1.15.0rc2, 1.15.0rc3, 1.15.0, 1.15.2, 1.15.3, 1.15.4, 1.15.5, 2.0.0a0, 2.0.0b0, 2.0.0b1, 2.0.0rc0, 2.0.0rc1, 2.0.0rc2, 2.0.0, 2.0.1, 2.0.2, 2.0.3, 2.0.4, 2.1.0rc0, 2.1.0rc1, 2.1.0rc2, 2.1.0, 2.1.1, 2.1.2, 2.1.3, 2.2.0rc0, 2.2.0rc1, 2.2.0rc2, 2.2.0rc3, 2.2.0rc4, 2.2.0, 2.2.1, 2.2.2, 2.3.0rc0, 2.3.0rc1, 2.3.0rc2, 2.3.0, 2.3.1, 2.3.2, 2.4.0rc0, 2.4.0rc1, 2.4.0rc2, 2.4.0rc3, 2.4.0rc4, 2.4.0, 2.4.1, 2.5.0rc0, 2.5.0rc1, 2.5.0rc2, 2.5.0rc3)
ERROR: No matching distribution found for tensorflow>2.4.1
According to section "Pre-release Versions" in the pip documentation:
If a Requirement specifier includes a pre-release or development version (e.g. >=0.0.dev0) then pip will allow pre-release and development versions for that requirement. This does not include the != flag.
This can be tested on the command line. As Tensorflow 2.5.0 is currently not yet released, we get:
$ pip download tensorflow~=2.5.0
ERROR: Could not find a version that satisfies the requirement tensorflow~=2.5.0 (from versions: 2.5.0rc0, 2.5.0rc1, 2.5.0rc2, 2.5.0rc3)
ERROR: No matching distribution found for tensorflow~=2.5.0
But if we add a pre-release version specifier:
$ pip download tensorflow~=2.5.0rc0
Collecting tensorflow~=2.5.0rc0
Downloading tensorflow-2.5.0rc3-cp39-cp39-win_amd64.whl (422.6 MB)
…
This would install the regular release once it becomes available.

Why does pip behave differently locally vs in a docker container?

So I have a requirements file that looks like this -
aiohttp==3.5.4
aioredis==1.2.0
amqp==2.4.2
asn1crypto==0.24.0
astroid==2.1.0
async-timeout==3.0.1
atomicwrites==1.3.0
# so on...
I run
pip install -r requirements.txt
locally and everything works fine.
However, when I use this Dockerfile
FROM python:2.7-slim
WORKDIR /app
COPY . /app
# Install any needed packages specified in requirements.txt
RUN pip install -r requirements.txt
EXPOSE 80
ENV FLASK_APP=iterative.py
ENV FLASK_ENV=development
RUN pip install gunicorn
CMD ["gunicorn -w 4 app:app"]
I get this error -
Could not find a version that satisfies the requirement aiohttp==3.5.4 (from -r requirements.txt (line 1)) (from versions: 0.1, 0.2, 0.3, 0.4, 0.4.1, 0.4.2, 0.4.3, 0.4.4, 0.5.0, 0.6.0, 0.6.1, 0.6.2, 0.6.3, 0.6.4, 0.6.5, 0.7.0, 0.7.1, 0.7.2, 0.7.3, 0.8.0, 0.8.1, 0.8.2, 0.8.3, 0.8.4, 0.9.0, 0.9.1, 0.9.2, 0.9.3, 0.10.0, 0.10.1, 0.10.2, 0.11.0, 0.12.0, 0.13.0, 0.13.1, 0.14.0, 0.14.1, 0.14.2, 0.14.3, 0.14.4, 0.15.0, 0.15.1, 0.15.2, 0.15.3, 0.16.0, 0.16.1, 0.16.2, 0.16.3, 0.16.4, 0.16.5, 0.16.6, 0.17.0, 0.17.1, 0.17.2, 0.17.3, 0.17.4, 0.18.0, 0.18.1, 0.18.2, 0.18.3, 0.18.4, 0.19.0, 0.20.0, 0.20.1, 0.20.2, 0.21.0, 0.21.1, 0.21.2, 0.21.4, 0.21.5, 0.21.6, 0.22.0a0, 0.22.0b0, 0.22.0b1, 0.22.0b2, 0.22.0b3, 0.22.0b4, 0.22.0b5, 0.22.0b6, 0.22.0, 0.22.1, 0.22.2, 0.22.3, 0.22.4, 0.22.5, 1.0.0, 1.0.1, 1.0.2, 1.0.3, 1.0.5, 1.1.0, 1.1.1, 1.1.2, 1.1.3, 1.1.4, 1.1.5, 1.1.6, 1.2.0, 1.3.0, 1.3.1, 1.3.2, 1.3.3, 1.3.4, 1.3.5, 2.0.0rc1, 2.0.0, 2.0.1, 2.0.2, 2.0.3, 2.0.4, 2.0.5, 2.0.6.post1, 2.0.7, 2.1.0, 2.2.0, 2.2.1, 2.2.2, 2.2.3, 2.2.4, 2.2.5, 2.3.0a4, 2.3.0, 2.3.1, 2.3.2b2)
No matching distribution found for aiohttp==3.5.4 (from -r requirements.txt (line 1))
Moreover, my python version locally is 2.7.15.
If I add
RUN pip install aiohttp
I get this error when building
aiohttp requires Python '>=3.4.2' but the running Python is 2.7.16
So I have two questions -
Why does my pip install work correctly locally, but when building my docker image?
Why does aiohttp require python version >=3.4.2, when I run in Docker, but not locally?
Thanks
Ok I solved this.
Ostensibly, the solution is to use a more modern version of python - I ended up using 3.6.
I think what was happening though was that pip was using python3, while python command lined was version 2.7.15.

Categories