prefer-uv-0-12
Why it matters
uv ships performance work continuously, and the 0.11 and 0.12 lines carried large batches that directly affect CI:
- 0.11: a reworked resolver (IDs-only PubGrub dependencies, reused resolver work across iterations, a compact index for lazy version maps, faster candidate selection), SIMD-accelerated TOML parsing, less redundant
pyproject.tomlparsing, and bytecode compilation limited to installed distributions. - 0.12: faster local and cold wheel extraction (single blocking ZIP task, reused readers and buffers, positioned reads), a concurrency-safe single-download/single-extract path for wheels, batched HTTP cache writes for cold-cache resolution, background-worker Simple API parsing, faster lockfile parsing and serialization, and profile-guided optimization (PGO) builds for Linux, Windows, and macOS.
Pinning uv below 0.12 keeps CI on the slower resolver and installer, so dependency resolution and installs take longer than necessary. uv has little compatibility risk between these releases, so there is usually no reason to keep an older pin.
What it flags
The rule reports jobs and repository configuration that resolve to a uv below 0.12:
astral-sh/setup-uvsteps whoseversionoruv-versioninput is below 0.12 (for example0.11.0or0.11.x).- Shell steps that pin uv during install, such as
pip install uv==0.11.5orpipx install "uv<0.12". - Repository configuration that constrains uv below 0.12:
required-versionin[tool.uv]oruv.toml,uv/uv_buildrequirement strings inpyproject.toml, and a.uv-versionfile.
Version constraints are read as a floor. A lower bound at or above 0.12 is accepted, and an upper bound that cannot reach 0.12 (for example <0.12) is flagged. latest and unpinned uv installs are not flagged because they already resolve to a current release.
Suggested action
- Raise the
astral-sh/setup-uvversioninput to at least0.12.x. - Update pinned
pip/pipxuv installs to0.12.xor newer. - Raise
required-versionin[tool.uv]/uv.toml, theuv/uv_buildrequirement string, or.uv-versionaccordingly.
Verification
Compare Python dependency resolution and install wall-clock time before and after moving uv to 0.12.x or newer, and confirm the resolved dependency set is unchanged.