mirror of
https://github.com/astral-sh/uv.git
synced 2025-11-01 04:17:37 +00:00
## Summary Normalize all `python_version` markers to their equivalent `python_full_version` form. This avoids false positives in forking because we currently cannot detect any relationships between the two forms. It also avoids subtle bugs due to the truncating semantics of `python_version`. For example, given `requires-python = ">3.12"`, we currently simplify the marker `python_version <= 3.12` to `false`. However, the version `3.12.1` will be truncated to `3.12` for `python_version` comparisons, and thus it satisfies the python requirement and evaluates to `true`. It is possible to simplify back to `python_version` when writing markers to the lockfile. However, the equivalent `python_full_version` markers are often clearer and easier to simplify, so I lean towards leaving them as `python_full_version`. There are *a lot* of snapshot updates from this change. I'd like more eyes on the transformation logic in `python_version_to_full_version` to ensure that they are all correct. Resolves https://github.com/astral-sh/uv/issues/6125. |
||
|---|---|---|
| .. | ||
| src | ||
| test-data/requirements-txt | ||
| Cargo.toml | ||