-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
github URL version dependency not parsed appropriately from setup.py
requirement
#8197
Comments
As you said, the Git tag does not necessarily match the version number. There is no way anyone can know the version, and thus it is not viable to parse the version out of it. The fact pip installs a different version from your expectation is entirely another issue, unrelated to the version parsing logic. As mentioned in #988 (comment), pip is now shipping a new resolver that would resolve a correct version out of the given specifiers. |
See also #7678 and linked issues. |
Thanks, the fact theres no version passed through is the real issue, I wasn't really sure how best to phrase it in the title of this issue. Seems like there's two separate paths for making this work - 1 parse out a version from a requirement specified like this, maybe use the tag specified as the 'version' the user required and installed for checking againtst or 2 - Retrieve the version from the URL somehow and use that to determine if a reinstall should happen. |
Environment
Description
When installing a dependency via a github URL in a
setup.py
file, the version is not matched and pip does not realise it needs to update the dependency.Expected behavior
The correct version number should be parsed from the github requirement and pip should realise it needs to upgrade the version
Note: This happens with or without the
-U
flagHow to Reproduce
pip install six==1.13.0
as a test packagesetup.py
as follows:pip install -e . -U
in the main directoryOutput
Notes
req = REQUIREMENT.parseString(requirement_string)
herespecifier
inrequirement_string == "six@git+https://github.com/benjaminp/six@1.14.0"
SpecifierSet
attached to this requirement is empty and pip subsequently does not check for a specific version when seeing if the requirement is satisifiedThe text was updated successfully, but these errors were encountered: