-
-
Notifications
You must be signed in to change notification settings - Fork 375
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
regex for pip explicit version ( ensure => '1.0a1' ) broken #310
Comments
Also impacting us with https://pypi.python.org/pypi/rucio/1.6.0.post2 |
For your info, I found the regular expression used by pip itself for the operator (==, <=, etc) with the the version of the package requested in line 2293 of /usr/lib/python2.6/site-packages/pip/vendor/pkg_resources/init.py |
+1 I'm not sure why we try and validate a version number at this stage. Puppet shouldn't be the enforcer of versioning styles. |
+1 I'm being affected by this issue as well. In my opinion, if you provide a version string yourself, and there's no match for that particular version in PyPI, it's your problem. I don't feel like this module should try to enforce a versioning scheme, I feel it should do what I mean, which is try to grab the version I told it to. |
While attempting to add pip package gsm0338 with version 1.0a1, I noted puppet actually trying and failing to UNinstall this package.
The regular expression here:
https://github.com/stankevich/puppet-python/blob/master/manifests/pip.pp#L150
will not catch a version like 1.0a1, or 0.31.1-1 and will attempt to uninstall the existing version, although this fails.
I note the Version formats comment here:
https://github.com/stankevich/puppet-python/blob/master/manifests/pip.pp#L213
However, that domain appears to be down, or infected with adware.
Seaching for guidelines, I found this page:
http://the-hitchhikers-guide-to-packaging.readthedocs.io/en/latest/specification.html
which would appear to suggest that examples such as 1.3a2.dev12 are acceptable
I would submit a patch, but I feel the lack of a patch is probably not the issue. Anyway, It's a simple regex mod, best left up to the developer who chose the current regex.
Question: Is there some political issue that requires packages to use only digits in the version scheme?
On my system, a quick check of pip freeze shows a not insignificant number of packages with version names that would not install with this puppet module.
The text was updated successfully, but these errors were encountered: