uv/crates/uv
Charlie Marsh e77ee15204
Enforce latest-version in `@latest` requests (#17114)
## Summary

Given `uv tool install {name}@latest`, we make revalidation requests for
`{name}`, but we don't actually add a "latest" constraint when resolving
-- we just assume that since the package is unpinned, and we're fetching
the latest available versions, the resolver will select the latest
version.

However, imagine a package in which the latest version requires Python
3.13 or later, but prior versions support Python 3.9 and up. If we
happen to select Python 3.9 ahead of resolution, and the user requests
`{name}@latest`, we would backtrack to the non-latest version due to the
Python mismatch.

This PR modifies `uv tool install` and `uv tool run` to first determine
the latest version, then provide it as a constraint when resolving.
2025-12-13 10:39:01 -05:00
..
src Enforce latest-version in `@latest` requests (#17114) 2025-12-13 10:39:01 -05:00
tests/it Update the exclude newer duration tests to demonstrate package version changes (#17055) 2025-12-10 07:47:44 -06:00
Cargo.toml Speed up cache size command (#17015) 2025-12-11 12:11:01 -05:00
README.md Bump version to 0.9.17 (#17058) 2025-12-09 16:36:00 -06:00
build.rs chore(🧹): const env var usage cleanup (#16950) 2025-12-02 22:16:46 -08:00

README.md