This release is a pre-release and may not be stable for production use.
feu 🔥
Overview
feu (French word for "fire" 🔥) is a lightweight Python library designed to help manage Python
packages and their versions across different Python environments.
Key Features
- ✅ Check package availability: Verify if packages and modules are installed
- 🔄 Version-aware installation: Install packages with automatic version compatibility checks
- 🎯 Smart version resolution: Find the closest valid package version for your target
environment (Python version, free-threadedness, OS, and CPU architecture). A version can be an
exact version (
2.4.0), a wildcard (2.4.*) or empty (the latest) - 📋 Package registry: Built-in compatibility information for popular packages (numpy, pandas, polars, torch, pydantic, etc.), which can be extended with your own constraints
- 🔍 PyPI-backed discovery: Discover version compatibility from the wheels published on PyPI, including for packages that aren't in the built-in registry
- 🔖 Version utilities: Compare, filter and sort versions, fetch the versions published on PyPI,
and read dependency bounds from
pyproject.toml - 🌿 Git and GitHub utilities: Get the tags of a local repository, and fetch and sort repository metadata from the GitHub API
- 🖥️ CLI tools: Command-line interface (
feu) to install a package, find the closest valid version, check if a version is valid and list the versions to test (pip install 'feu[cli]') - 🪶 Lightweight: Minimal dependencies (only
packagingrequired for core functionality)
Quick Example
The examples are doctests: they are run by the test suite, so they cannot drift from the code.
>>> from feu import is_package_available
>>> from feu.compat import Target, find_closest_version
>>> is_package_available("packaging")
True
>>> # The closest valid version for a target (Python 3.9 on Linux x86_64)
>>> target = Target(python_version="3.9", os="linux", arch="x86_64")
>>> find_closest_version("numpy", "2.3.0", target)
'2.0.2'
>>> # A version is a request: an exact version, a wildcard or "" for the latest
>>> find_closest_version("numpy", "1.*", target)
'1.26.4'
>>> # A target without a platform means "any platform"
>>> find_closest_version("numpy", "2.3.0", Target(python_version="3.9"))
'2.0.2'
The same checks are available from the command line (pip install 'feu[cli]'). The standard
output holds only the answer and the exit status carries the result (0 ok, 1 negative answer,
2 usage error):
feu find-closest-version --pkg-name=numpy --pkg-version=2.0.2 --python-version=3.10
feu check-valid-version --pkg-name=numpy --pkg-version=2.0.2 --python-version=3.10
feu install --pkg-name=numpy --pkg-version=2.0.2
python -m feu ... is equivalent.
Why feu?
Managing Python package versions across different Python versions can be challenging. Different
Python versions support different package versions, and manually tracking compatibility can be
error-prone. feu solves this by:
- Automating version selection: Automatically finds compatible package versions for your Python environment
- Preventing installation failures: Validates versions before installation to avoid runtime errors
- Simplifying multi-version support: Makes it easy to support multiple Python versions in your projects
- Providing graceful fallbacks: Check package availability and provide alternatives when packages aren't installed
Documentation
- 📚 Full Documentation
- 🚀 Get Started Guide
- 📖 Usage Examples
- 🧭 Properties: the rules
feufollows - 🧱 Architecture: layers, how to add a package, an installer or a resolver
- 🔀 Migration to 0.9
- 🖥️ CLI Reference
- 📚 API Reference
Quick Links
Installation
We highly recommend installing
a virtual environment.
feu can be installed from pip using the following command:
pip install feu
To make the package as slim as possible, only the minimal packages required to use feu are
installed. To include all the dependencies, you can use the following command:
pip install feu[all]
Please check the get started page to see how to
install only some specific dependencies (feu[cli], feu[git], feu[requests], feu[rich]) or
other alternatives to install the library. The following
is the corresponding feu versions and supported dependencies.
feu |
packaging |
python |
click* |
gitpython* |
requests* |
rich* |
|---|---|---|---|---|---|---|
main |
>=22.0,<27.0 |
>=3.11 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
>=14.0.0,<16.0 |
0.8.4 |
>=21.0,<27.0 |
>=3.10 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
>=14.0.0,<16.0 |
0.8.3 |
>=21.0,<27.0 |
>=3.10 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
>=14.0.0,<16.0 |
0.8.2 |
>=21.0,<27.0 |
>=3.10 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
>=14.0.0,<16.0 |
0.8.1 |
>=21.0,<27.0 |
>=3.10 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
>=14.0.0,<16.0 |
0.8.0 |
>=21.0,<27.0 |
>=3.10 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
>=14.0.0,<16.0 |
0.7.3 |
>=21.0,<27.0 |
>=3.10 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
|
0.7.2 |
>=21.0,<27.0 |
>=3.10 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
|
0.7.1 |
>=21.0,<27.0 |
>=3.10 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
|
0.7.0 |
>=21.0,<27.0 |
>=3.10 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
|
0.6.2 |
>=21.0,<27.0 |
>=3.10 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
|
0.6.1 |
>=21.0,<26.0 |
>=3.10 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
|
0.6.0 |
>=21.0,<26.0 |
>=3.10 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
|
0.5.0 |
>=21.0,<26.0 |
>=3.10,<3.15 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
* indicates an optional dependency
older versions
feu |
packaging |
python |
click* |
gitpython* |
fire* |
requests* |
|---|---|---|---|---|---|---|
0.4.2 |
>=21.0,<26.0 |
>=3.10,<3.15 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
|
0.4.1 |
>=21.0,<26.0 |
>=3.10,<3.15 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
|
0.4.0 |
>=21.0,<26.0 |
>=3.9,<3.14 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
>=2.30,<3.0 |
|
0.3.5 |
>=21.0,<26.0 |
>=3.9,<3.14 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
||
0.3.4 |
>=21.0,<26.0 |
>=3.9,<3.14 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
||
0.3.3 |
>=21.0,<26.0 |
>=3.9,<3.14 |
>=8.1,<9.0 |
>=3.1.41,<4.0 |
||
0.3.2 |
>=21.0,<25.0 |
>=3.9,<3.14 |
>=8.1,<9.0 |
|||
0.3.1 |
>=21.0,<25.0 |
>=3.9,<3.14 |
>=8.1,<9.0 |
|||
0.3.0 |
>=21.0,<25.0 |
>=3.9,<3.14 |
>=8.1,<9.0 |
|||
0.2.4 |
>=21.0,<25.0 |
>=3.9,<3.13 |
>=8.1,<9.0 |
|||
0.2.3 |
>=21.0,<25.0 |
>=3.9,<3.13 |
>=8.1,<9.0 |
|||
0.2.2 |
>=21.0,<25.0 |
>=3.9,<3.13 |
>=8.1,<9.0 |
|||
0.2.1 |
>=21.0,<25.0 |
>=3.9,<3.13 |
>=8.1,<9.0 |
|||
0.2.0 |
>=21.0,<25.0 |
>=3.9,<3.13 |
>=8.1,<9.0 |
|||
0.1.1 |
>=21.0,<25.0 |
>=3.9,<3.13 |
>=0.6.0,<1.0 |
|||
0.1.0 |
>=21.0,<25.0 |
>=3.9,<3.13 |
>=0.6.0,<1.0 |
|||
0.0.7 |
>=21.0,<25.0 |
>=3.9,<3.13 |
||||
0.0.6 |
>=21.0,<25.0 |
>=3.9,<3.13 |
||||
0.0.5 |
>=21.0,<25.0 |
>=3.9,<3.13 |
||||
0.0.4 |
>=21.0,<25.0 |
>=3.9,<3.13 |
||||
0.0.3 |
>=21.0,<25.0 |
>=3.9,<3.13 |
||||
0.0.2 |
>=22.0,<24.0 |
>=3.9,<3.13 |
||||
0.0.1 |
>=22.0,<23.3 |
>=3.9,<3.13 |
Contributing
Please check the instructions in CONTRIBUTING.md.
Suggestions and Communication
Everyone is welcome to contribute to the community. If you have any questions or suggestions, you can submit Github Issues. We will reply to you as soon as possible. Thank you very much.
API stability
⚠️ While feu is in development stage, no API is guaranteed to be stable from one release to
the next. In fact, it is very likely that the API will change multiple times before a stable 1.0.0
release. In practice, this means that upgrading feu to a new version will possibly break any code
that was using the old version of feu.
License
feu is licensed under BSD 3-Clause "New" or "Revised" license available in LICENSE
file.
Metadata
Release files for feu 0.9.0a0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| feu-0.9.0a0.tar.gz | 123.7 kB | Without provenance | Details for feu-0.9.0a0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| feu-0.9.0a0-py3-none-any.whl | Python 3 | none | any | Details for feu-0.9.0a0-py3-none-any.whl |
Total release size: 213.0 kB
Release files / feu-0.9.0a0.tar.gz
| Download URL | feu-0.9.0a0.tar.gz |
|---|---|
| Size | 123.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b6147c1736483f2a55698f2b2aa67ed867438b719cbcc0f102776d9545196522
|
|
BLAKE2b-256 checksum How to use checksums |
d23adcacbd65a2c3b3c62ea09a0fd3bd0a10e66b7625fdd795ed5222e1fcce41
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.13.8 {"installer":{"name":"uv","version":"0.13.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / feu-0.9.0a0-py3-none-any.whl
| Download URL | feu-0.9.0a0-py3-none-any.whl |
|---|---|
| Size | 89.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f0b152bae63d12926992d4029d9c31b919ac962856249113b9e4d5ceedaa1aee
|
|
BLAKE2b-256 checksum How to use checksums |
16d5c6e96e3cdd8b72da3f9596708194068ee49acb5a8366dcc94ed1dacd2e42
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.13.8 {"installer":{"name":"uv","version":"0.13.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Security for feu 0.9.0a0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.