uv-dynamic-versioning is a plugin for `uv` (and `hatch`) that provides dynamic versioning capabilities for Python projects, typically by deriving versions from Git VCS tags. It's built on top of `setuptools_scm` and offers various configuration options for version formatting and bumping. The current version is 0.14.0, with frequent minor releases addressing features, bug fixes, and documentation.
pip install uv-dynamic-versioningVerified import paths — ran on the pinned version, not inferred.
Configure dynamic versioning in your `pyproject.toml` and then use `uv build` to build your project, allowing `uv-dynamic-versioning` to automatically determine and apply the version based on your VCS tags.
Ensure all configuration values in `pyproject.toml` (e.g., `bump`, `tag`) are set with their correct Python type (e.g., `bump = true` instead of `bump = "true"`).
Ensure your development and build environments are running Python 3.10 or newer. Python 3.9 is no longer supported.
To force a fresh build and ensure the latest dynamic version is applied, use `uv clean --all` or `uv build --refresh` before building your project. Refer to `uv`'s documentation on caching for more details.
Focus on configuring the tool via `pyproject.toml` and leveraging your chosen build orchestrator (`uv` or `hatch`) rather than attempting to import and call functions from `uv_dynamic_versioning` in your Python application.