Skip to main content

Release Python License Downloads Tests Coverage

extremal-python-dependencies

A utility for installing extremal versions of dependencies for more robust testing.

Install extremal versions of package dependencies for more robust continuous integration testing, given a package that specifies its dependencies in a pyproject.toml file.

For instance, one might use this utility to install the minimum supported version of each dependency before a CI run. Ensuring all tests then pass adds confidence that the code is indeed compatible with the full range of package versions it claims to be compatible with, helping to prevent users from encountering broken installs.

Another way to use this tool is to install development versions of certain packages.

This utility works with dependencies specified in a pyproject.toml file. It modifies pyproject.toml, either by sending the transformed version to stdout (the default) or by modifying in place (which may be useful in CI scripts).

How to use

The following snippet modifies pyproject.toml in place to test with the minimum supported version of each direct dependency, under the minimum supported tox version (as specified by minversion in tox.ini).

pip install "tox==$(extremal-python-dependencies get-tox-minversion)"
extremal-python-dependencies pin-dependencies-to-minimum --inplace
tox -epy

The following snippet modifies pyproject.toml in place to test with the development version of one or more dependencies:

extremal-python-dependencies pin-dependencies \
    "qiskit @ git+https://github.com/Qiskit/qiskit.git" \
    "qiskit-ibm-runtime @ git+https://github.com/Qiskit/qiskit-ibm-runtime.git" \
    --inplace
tox -epy

Each of the above patterns can be used in a CI script.

Caveats

  • The minimum versions of all optional dependencies installed simultaneously must be compatible with each other.
  • This tool does not set the minimum supported version of transitive dependencies.

Similar tools

  • requirements-builder: builds requirements from a setup.py file instead of a pyproject.toml file
  • uv's --resolution strategies: lowest-direct installs the lowest compatible versions of direct dependencies (similar to the pin-dependencies pattern above), while lowest extends this to transitive dependencies as well — addressing a caveat of this tool. If extremal-python-dependencies does not meet your needs, uv may.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

extremal_python_dependencies-1.0.0.tar.gz (14.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

extremal_python_dependencies-1.0.0-py3-none-any.whl (13.6 kB view details)

Uploaded Python 3

File details

Details for the file extremal_python_dependencies-1.0.0.tar.gz.

File metadata

File hashes

Hashes for extremal_python_dependencies-1.0.0.tar.gz
Algorithm Hash digest
SHA256 c22334908e8707ef9b7e75b528c4eacc1c890417dc32d14b7b0265415b227df4
MD5 7a54d19b82e499d031252dc627d42284
BLAKE2b-256 26bc3a9c92a3ca9d589e5fee5d30de901a9b57c95bfaee4a5b2f201ca794c018

See more details on using hashes here.

Provenance

The following attestation bundles were made for extremal_python_dependencies-1.0.0.tar.gz:

Publisher: release.yml on IBM/extremal-python-dependencies

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file extremal_python_dependencies-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for extremal_python_dependencies-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 cf2db865ea0590711026620efac15dd8c40408463eb542ed3f316a2c6024b25b
MD5 52e21161196d5bf2fdb40d89c3d23088
BLAKE2b-256 08b9956ea28d98b5405b0619f23e297461ec657080f1209c0290cac4cb1dafce

See more details on using hashes here.

Provenance

The following attestation bundles were made for extremal_python_dependencies-1.0.0-py3-none-any.whl:

Publisher: release.yml on IBM/extremal-python-dependencies

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page