astral-sh / astral-sh/uv-pre-commit
uv-lock hook can pass with an outdated lockfile when UV_FROZEN=1
- Dominant language
- Python
- Stars
- 348
- Forks
- 27
- PR merge metrics
- No merged PRs in 30d
Description
With UV_FROZEN=1, the uv-lock hook can pass even when the lockfile is outdated.
This caused problems for us in CI, where UV_FROZEN=1 is commonly set: a change that should have required a lockfile update was not caught.
Expected: Hook fails when lockfile is outdated.
Actual: Hook does not update the lockfile and does not fail, so lockfile drift can pass unnoticed.
Workaround: Set UV_FROZEN=0 for uv-lock hook execution only.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by tracing the uv-lock hook entry point and how it handles UV_FROZEN=1. Reproduce the issue with an outdated lockfile, then verify that the hook fails rather than passing; add or update the relevant test if the repository provides one.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 58/100