Parsing of Wheel version from PEP508 url does not completely extract version number #1931
Closed
3 tasks done
Labels
kind/bug
Something isn't working as expected
I am on the latest Poetry version.
I have searched the issues of this repo and believe that this is not a duplicate.
If an exception occurs when executing a command, I executed it again in debug mode (
-vvv
option).OS version and name: MacOS 10.14.6 Mojave
Poetry version: 1.0.2
Link of a Gist with the contents of your pyproject.toml file: n/a
Issue
When a dependency has a dependency with a PEP508 '@' URI reference pointing to a wheel, and particularly when the version of the requirement is >=10 then the version it parses is incorrect. Specifically it only parses the first digit of the version number.
In our case, our dependency (here
ourdep
) has the following metadata:(private url censored)
Then we see in the debug logs:
And therefore
pippi update -vvv
fails with aSolverProblemError
.This is caused by the regexp for wheels in
poetry/packages/__init__.py
independency_from_pep_508()
:which is too non-greedy and only matches the first digit:
As you can see from the pdb session above, it only matches
log_setup-1
notlog_setup-14
orlog_setup-14.0.0
.The text was updated successfully, but these errors were encountered: