A standalone variant of packaging.version, without anything else.
Project description
verlib2
» Changelog | PyPI | Issues | Source code | License
About
A standalone variant of packaging.version
, without anything else.
verlib is the implementation of PEP 386. verlib2 is the implementation of PEP 440.
Rationale
Everyone needs to compare versions, but no one wants to add packaging
as a dependency.
distutils
is deprecated, and Python 3.12 removed it from the standard library.
Setup
pip install verlib2
Usage
from verlib2 import Version
assert Version("1.0.dev456") < Version("1!1.2.rev33+123456")
Acknowledgements
Tarek Ziadé, Donald Stufft, and all contributors to distutilsversion
, verlib
,
distutils
, distutils2
, packaging.version
, PEP-0386, PEP-0440, and most
probably more.
Prior Art
- https://peps.python.org/pep-0386/
- https://peps.python.org/pep-0440/
- http://bitbucket.org/tarek/distutilsversion/
- https://pypi-hypernode.com/project/verlib/
- https://hg.python.org/distutils2
- https://github.com/pypa/packaging/blob/23.2/src/packaging/version.py
- https://github.com/numpy/numpy/pull/21000
- https://github.com/numpy/numpy/blob/v1.26.0/numpy/_utils/_pep440.py
- https://github.com/crate/crate-python/pull/513
- https://pypi-hypernode.com/search/?q=pep440
- https://pypi-hypernode.com/project/pep440/
- https://pypi-hypernode.com/project/pep440deb/
- https://pypi-hypernode.com/project/pep440nz/
- https://pypi-hypernode.com/project/pep440-rs/
- https://pypi-hypernode.com/project/pep440-utility/
- https://pypi-hypernode.com/project/pep440-version-utils/
- https://pypi-hypernode.com/project/version-utils/
Development
Set up package in development mode.
python3 -m venv .venv
source .venv/bin/activate
pip install --editable='.[develop,test]'
Run software tests.
poe check
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file verlib2-0.2.0.tar.gz
.
File metadata
- Download URL: verlib2-0.2.0.tar.gz
- Upload date:
- Size: 10.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0ab94087c094e27163948dfa817c98d62b6bdd01226cce5188f8cc3cd68345b9 |
|
MD5 | c7b9125a3dfeebad31f92eb10a8f8084 |
|
BLAKE2b-256 | 7ae3a27d3b956f9ba6dcdf1404474c466d29bf219cc92f803cbbb3a7f698abe1 |
File details
Details for the file verlib2-0.2.0-py3-none-any.whl
.
File metadata
- Download URL: verlib2-0.2.0-py3-none-any.whl
- Upload date:
- Size: 8.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c0fb8dbae76e228e55bb6178207cda931d44c843d8485c873b7676835edf2e8f |
|
MD5 | 36433ebc4a04041d59a2d7ba98b12309 |
|
BLAKE2b-256 | 48d3ec173825185edcb54b950237561c5cf2310e8fb9f288974652449e0a079e |