Skip to main content

looseversion - Version numbering for anarchists and software realists

A backwards/forwards-compatible fork of distutils.version.LooseVersion, for times when PEP-440 isn't what you need.

The goal of this package is to be a drop-in replacement for the original LooseVersion. It implements an identical interface and comparison logic to LooseVersion. The only major change is that a looseversion.LooseVersion is comparable to a distutils.version.LooseVersion, which means tools should not need to worry whether all dependencies that use LooseVersion have migrated.

If you are simply comparing versions of Python packages, consider moving to packaging.version.Version, which follows PEP-440. LooseVersion is better suited to interacting with heterogeneous version schemes that do not follow PEP-440.

Installation

From PyPI

pip install looseversion

From source

git clone https://github.com/effigies/looseversion.git
pip install looseversion/

Usage

>>> from looseversion import LooseVersion
>>> LooseVersion("1.0.0") < LooseVersion("2.0.0")
True
>>> LooseVersion("1.0.0") < "2"
True

Release files for looseversion 1.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for looseversion 1.3.0
File Size Uploaded
looseversion-1.3.0.tar.gz 8.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for looseversion 1.3.0
File Interpreter ABI Platform
looseversion-1.3.0-py2.py3-none-any.whl Python 3, Python 2 none any Details

Total release size: 17.0 kB

Release files / looseversion-1.3.0.tar.gz

Download URL looseversion-1.3.0.tar.gz
Size 8.8 kB
Tags Source
SHA-256 checksum
How to use checksums
ebde65f3f6bb9531a81016c6fef3eb95a61181adc47b7f949e9c0ea47911669e
BLAKE2b-256 checksum
How to use checksums
647ef13dc08e0712cc2eac8e56c7909ce2ac280dbffef2ffd87bd5277ce9d58b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/4.0.1 CPython/3.11.4

Release files / looseversion-1.3.0-py2.py3-none-any.whl

Download URL looseversion-1.3.0-py2.py3-none-any.whl
Size 8.2 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
781ef477b45946fc03dd4c84ea87734b21137ecda0e1e122bcb3c8d16d2a56e0
BLAKE2b-256 checksum
How to use checksums
4e74d5405b9b3b12e9176dff223576d7090bc161092878f533fd0dc23dd6ae1d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/4.0.1 CPython/3.11.4

Release history Release notifications | RSS feed

This release

1.3.0 This release

2 release files

1.2.0

2 release files

1.1.2

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.3

2 release files

1.0.2

2 release files

1.0.1

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page