[docutils:bugs] #473 Pip installs an incompatible version (20.1) for Python 2
"Günter Milde" via Docutils-develop <[email protected]>
| Newsgroups | gmane.text.docutils.devel |
|---|---|
| Message-ID | </p/docutils/bugs/473/475bf36933fb87fc6ba47629905744caa106b71d.bugs@docutils.p.sourceforge.net> |
- **status**: open --> open-fixed
- **Comment**:
> The output of pip install docutils -vvv shows that previous versions are correctly rejected, but 20.1 is accepted for some reason:
Actually, links to incompatible *wheels* (`*.whl`) are skipped but **all** *source package* links `*.tar.gz` are considered for the next step (selecting the newest).
After downloading the newest tar.gz (instead of a compatible wheel!), it starts:
>
Running setup.py (path:/tmp/pip-build-U_uehq/docutils/setup.py) egg_info for package docutils
Running command python setup.py egg_info
/usr/lib64/python2.7/distutils/dist.py:267: UserWarning: Unknown distribution option: 'python_requires'
warnings.warn(msg)
IAW, the item `'python-requires': '>=3.7'` in the `package_data` is ignored and
the package set up despite the incompatibility :(
As a workaround, one could consider a Python-version check throwing an Exeption under 2.x.
However, since [r9450] there is no `setup.py` (replaced by a `pyproject.tom`).
This should also lead to older `pip` versions failing instead of installing an icompatible version
(or, maybe, even to installing the correct version...).
---
**[bugs:#473] Pip installs an incompatible version (20.1) for Python 2**
**Status:** open-fixed
**Created:** Thu Aug 31, 2023 10:29 AM UTC by Richard Fennessy
**Last Updated:** Sun Nov 12, 2023 06:00 PM UTC
**Owner:** nobody
Hi,
Recently, we've noticed that running the command `pip install docutils` on an old host with only Python 2 installed has begun to install an incompatible version, `20.1`. (First noticed when the incompatibility broke `awscli`).
The output of `pip install docutils -vvv` shows that previous versions are correctly rejected, but `20.1` is accepted for some reason:
(truncated for clarity)
~~~
Found link https://files.pythonhosted.org/packages/57/b1/b880503681ea1b64df05106fc7e3c4e3801736cf63deffc6fa7fc5404cf5/docutils-0.18.1.tar.gz#sha256=679987caf361a7539d76e584cbeddc311e3aee937877c87346f31debc63e9d06 (from https://pypi.org/simple/docutils/), version: 0.18.1
Found link https://files.pythonhosted.org/packages/ac/f7/aec2c4e0acabe771b207ff2b480f2bc1adaef02771ff12f9561e66df33cf/docutils-0.19b1-py2.py3-none-any.whl#sha256=bf87502630148119873347981a8efc2438e6f254f995b7699501f0e4aa538915 (from https://pypi.org/simple/docutils/), version: 0.19b1
Found link https://files.pythonhosted.org/packages/cf/65/85a3da30f9a256a29b9cf947d603848eb6a4339900df73fbd56551c8b844/docutils-0.19b1.tar.gz#sha256=79b3ab5228b154ecaf4cbf08a1d8c213e3a127826193bafb5a035d0a7a88af0c (from https://pypi.org/simple/docutils/), version: 0.19b1
Skipping link https://files.pythonhosted.org/packages/93/69/e391bd51bc08ed9141ecd899a0ddb61ab6465309f1eb470905c0c8868081/docutils-0.19-py3-none-any.whl#sha256=5e1de4d849fee02c63b040a4a3fd567f4ab104defd8a5511fbbc24a8a017efbc (from https://pypi.org/simple/docutils/); it is not compatible with this Python
Found link https://files.pythonhosted.org/packages/6b/5c/330ea8d383eb2ce973df34d1239b3b21e91cd8c865d21ff82902d952f91f/docutils-0.19.tar.gz#sha256=33995a6753c30b7f577febfc2c50411fec6aac7f7ffeb7c4cfe5991072dcf9e6 (from https://pypi.org/simple/docutils/), version: 0.19
Skipping link https://files.pythonhosted.org/packages/73/f1/455c0f5f29e853956947745299e65c494fe7ed49bce41fd05a738d931da3/docutils-0.20rc1-py3-none-any.whl#sha256=f9cd313159e9611199127c59b63c4890e808cb8cb6c2fe5f9a271cfd6df32676 (from https://pypi.org/simple/docutils/); it is not compatible with this Python
Found link https://files.pythonhosted.org/packages/1d/0e/f03180dcf1e0727083dc5a303f15cacaf7ae1686f0a4efc295f5ff938197/docutils-0.20rc1.tar.gz#sha256=1077d5e5a529972f340550a99f55c59420095e40eb0eef0824083557a6589e98 (from https://pypi.org/simple/docutils/), version: 0.20rc1
Skipping link https://files.pythonhosted.org/packages/41/3b/11740ed0f36e408ff3d5bd259af0c3330d899c17562f9964b7fbc90756f9/docutils-0.20-py3-none-any.whl#sha256=a428f10de4de4774389734c986a01b4af2d802d26717108b0f1b9356862937c5 (from https://pypi.org/simple/docutils/); it is not compatible with this Python
Found link https://files.pythonhosted.org/packages/e6/a9/8ddfaa7a9414e42520e0041d1354ebda699e4eb1b47e2f1b6d8bda66aba6/docutils-0.20.tar.gz#sha256=f75a5a52fbcacd81b47e42888ad2b380748aaccfb3f13af0fe69deb759f01eb6 (from https://pypi.org/simple/docutils/), version: 0.20
Skipping link https://files.pythonhosted.org/packages/26/87/f238c0670b94533ac0353a4e2a1a771a0cc73277b88bff23d3ae35a256c1/docutils-0.20.1-py3-none-any.whl#sha256=96f387a2c5562db4476f09f13bbab2192e764cac08ebbf3a34a95d9b1e4a59d6 (from https://pypi.org/simple/docutils/); it is not compatible with this Python
Found link https://files.pythonhosted.org/packages/1f/53/a5da4f2c5739cf66290fac1431ee52aff6851c7c8ffd8264f13affd7bcdd/docutils-0.20.1.tar.gz#sha256=f08a4e276c3a1583a86dce3e34aba3fe04d02bba2dd51ed16106244e8a923e3b (from https://pypi.org/simple/docutils/), version: 0.20.1
Using version 0.20.1 (newest of versions: 0.3, 0.3.5, 0.3.7, 0.3.9, 0.4, 0.5, 0.6, 0.7, 0.8, 0.8.1, 0.9, 0.9.1, 0.10, 0.11, 0.12, 0.13.1, 0.14, 0.15, 0.15.post1, 0.15.1, 0.15.1.post1, 0.15.2, 0.16, 0.17, 0.17.1, 0.18, 0.18.1, 0.19, 0.20, 0.20.1)
Looking up "https://files.pythonhosted.org/packages/1f/53/a5da4f2c5739cf66290fac1431ee52aff6851c7c8ffd8264f13affd7bcdd/docutils-0.20.1.tar.gz" in the cache
Current age based on date: 759150
Freshness lifetime from max-age: 365000000
The response is "fresh", returning cached response
365000000 > 759150
Using cached https://files.pythonhosted.org/packages/1f/53/a5da4f2c5739cf66290fac1431ee52aff6851c7c8ffd8264f13affd7bcdd/docutils-0.20.1.tar.gz
Downloading from URL https://files.pythonhosted.org/packages/1f/53/a5da4f2c5739cf66290fac1431ee52aff6851c7c8ffd8264f13affd7bcdd/docutils-0.20.1.tar.gz#sha256=f08a4e276c3a1583a86dce3e34aba3fe04d02bba2dd51ed16106244e8a923e3b (from https://pypi.org/simple/docutils/)
Running setup.py (path:/tmp/pip-build-U_uehq/docutils/setup.py) egg_info for package docutils
Running command python setup.py egg_info
/usr/lib64/python2.7/distutils/dist.py:267: UserWarning: Unknown distribution option: 'python_requires'
warnings.warn(msg)
running egg_info
creating pip-egg-info/docutils.egg-info
writing pip-egg-info/docutils.egg-info/PKG-INFO
writing top-level names to pip-egg-info/docutils.egg-info/top_level.txt
writing dependency_links to pip-egg-info/docutils.egg-info/dependency_links.txt
writing entry points to pip-egg-info/docutils.egg-info/entry_points.txt
writing manifest file 'pip-egg-info/docutils.egg-info/SOURCES.txt'
warning: manifest_maker: standard file '-c' not found
package init file 'docutils/parsers/rst/include/__init__.py' not found (or not a regular file)
package init file 'docutils/writers/s5_html/themes/__init__.py' not found (or not a regular file)
package init file 'docutils/writers/s5_html/themes/default/__init__.py' not found (or not a regular file)
reading manifest file 'pip-egg-info/docutils.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no previously-included files found matching 'test/alltests.out'
warning: no previously-included files found matching 'test/record.txt'
warning: no previously-included files matching '*.pyc' found anywhere in distribution
warning: no previously-included files matching '*~' found anywhere in distribution
warning: no previously-included files matching '__pycache__' found anywhere in distribution
warning: no previously-included files matching '.DS_Store' found anywhere in distribution
writing manifest file 'pip-egg-info/docutils.egg-info/SOURCES.txt'
Source in /tmp/pip-build-U_uehq/docutils has version 0.20.1, which satisfies requirement docutils from https://files.pythonhosted.org/packages/1f/53/a5da4f2c5739cf66290fac1431ee52aff6851c7c8ffd8264f13affd7bcdd/docutils-0.20.1.tar.gz#sha256=f08a4e276c3a1583a86dce3e34aba3fe04d02bba2dd51ed16106244e8a923e3b
~~~
pip version 8.1.2
CentOS Linux 7 (Core)
Linux 3.10.0-1160.95.1.el7.x86_64
---
Sent from sourceforge.net because [email protected] is subscribed to https://sourceforge.net/p/docutils/bugs/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/docutils/admin/bugs/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.