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
Add checker for PyPI packages #120
Conversation
53b1c7c
to
bca011c
Compare
d905842
to
eb621ec
Compare
eb621ec
to
ffbdbfd
Compare
@gasinvein is the intent to allow wheels which contain compiled binaries? |
In future maybe, but currently not. It should skip all wheel with ABI. |
What about compatibility? There's no guarantee pip packages are actually compatible with each other if you just update one. |
I don't think there is much we can do about it, except to provide an option for limiting suitable package versions like this: |
try: | ||
matches = oper(StrictVersion(version), StrictVersion(ver_limit)) | ||
except ValueError: | ||
matches = oper(LooseVersion(version), LooseVersion(ver_limit)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Iirc current version PEP is superset of this. It's probably close enough though.
Looks good to me |
Hmm, AFAIK python allows only one version constraint in requirements. Maybe we should do the same? It will reduce complexity a bit. |
It actually supports multiple in same line so you can declare a range. |
Well then. Didn't know this, how it looks like? |
@gasinvein https://github.com/psf/requests/blob/master/setup.py#L45, basically you just have comma as separator. |
@nanonyme And the comma does conjunction, right? If so, I guess the checker version constraints would behave more or less same as requirement notation. |
Yes, indeed. Checker should work fine as is. |
Given PyPI package name and desired dist type (
sdist
orbdist_wheel
), this checker finds latest available release.Fixes #74, see test manifest for usage example.
I would appreciate a review from @nanonyme who is more familiar with PyPI and previously worked on something similar for BuildStream.