[Bug 1905064] [NEW] "+" suffix in 3.9.0+ breaks pip
Cédric Cabessa
1905064 at bugs.launchpad.net
Fri Nov 20 17:20:57 UTC 2020
Public bug reported:
python3.9 in focal is versioned as 3.9.0+
According to pip this is considered as a "LegacyVersion", which break
comparison
https://github.com/pypa/pip/blob/20.2.4/src/pip/_vendor/packaging/version.py#L48
Here is a snippet that show the "+" break comparison
```
>>> from pip._vendor.packaging.version import parse
>>> parse("3.9.0+")
<LegacyVersion('3.9.0+')>
>>> parse("3.9.0")
<Version('3.9.0')>
>>> parse("3.9.0+") >= parse("3.6.0")
False
>>> parse("3.9.0") >= parse("3.6.0")
True
>>>
```
Is it possible to mark this version as 3.9.0 ?
It seems the plus is introduced by a debian patch.
Thank you
** Affects: python3.9 (Ubuntu)
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to python3.9 in Ubuntu.
https://bugs.launchpad.net/bugs/1905064
Title:
"+" suffix in 3.9.0+ breaks pip
Status in python3.9 package in Ubuntu:
New
Bug description:
python3.9 in focal is versioned as 3.9.0+
According to pip this is considered as a "LegacyVersion", which break
comparison
https://github.com/pypa/pip/blob/20.2.4/src/pip/_vendor/packaging/version.py#L48
Here is a snippet that show the "+" break comparison
```
>>> from pip._vendor.packaging.version import parse
>>> parse("3.9.0+")
<LegacyVersion('3.9.0+')>
>>> parse("3.9.0")
<Version('3.9.0')>
>>> parse("3.9.0+") >= parse("3.6.0")
False
>>> parse("3.9.0") >= parse("3.6.0")
True
>>>
```
Is it possible to mark this version as 3.9.0 ?
It seems the plus is introduced by a debian patch.
Thank you
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/python3.9/+bug/1905064/+subscriptions
More information about the foundations-bugs
mailing list