-
Notifications
You must be signed in to change notification settings - Fork 253
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
Is there a StrictVersion
after we drop distutils
?
#520
Comments
Our normal |
znewman01
added a commit
to znewman01/securesystemslib
that referenced
this issue
Sep 30, 2022
distutils is deprecated as of Python 3.10. We were only using it for `StrictVersion`, which parses a version string and lets you order the result. The [official recommendation] from the packaging team is to replace `StrictVersion` with a dependency on the `packaging` package, but: 1. The Python version parser was a little different from GPG versioning anyway because it's made for Python versions (it had support for "prerelease tags"). 2. I wanted to avoid adding dependencies if possible. [official recommendation]: pypa/packaging#520 This PR adds a new `Version` class in `securesystemslib.gpg.util` and uses that instead. Signed-off-by: Zachary Newman <[email protected]>
3 tasks
7 tasks
3 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
We currently use
from distutils.version import StrictVersion
but we want to dropdistutils
in preparation for Python 3.12. What is the recommended substitute forStrictVersion
? https://github.com/python/cpython/blob/main/Lib/distutils/version.py#L93https://github.com/pypa/packaging/blob/main/packaging/version.py
The text was updated successfully, but these errors were encountered: