uv icon indicating copy to clipboard operation
uv copied to clipboard

Support exact `requires-python` version in generating `pylock.toml`

Open ketozhang opened this issue 6 months ago • 0 comments

Summary

Currently, uv pip compile SRC_FILE -o pylock.toml --python-version 3.12.10 resolves to:

# ...
lock-version = "1.0"
created-by = "uv"
requires-python = ">=3.12.10"
# ...

The problem for me is I do not intend to deploy 3.13 regardless if 3.13 is compatible with this lock file.

In the use case of deploying reproducible environments including the installation of Python, it would be nice to not need to also specify --python or the .python_version file.

Example

No response

ketozhang avatar May 16 '25 19:05 ketozhang