Work Log - 2026-10-25
π― Focus for Today¶
Thinking about keeping dependencies synced to the latest upstream stable
versions. The gap: uv sync installs from uv.lock and never upgrades, so
lockfiles drift behind PyPI silently β this week vibes picked up a zensical
jump of ten point releases that had been sitting unselected for a while.
β What Got Done¶
- Added a
pre-pushgit hook (.githooks/pre-push) that runsuv lock --upgradeagainst a snapshot ofuv.lock, diffs, and blocks the push if the resolution would change anything. On failure it restores the original lockfile, so the working tree stays clean and the fix is always the same:uv lock --upgrade && uv sync, commit, push again. - Installed the same hook in this repo (public/opsdev.nz) and set
core.hooksPath; it flagged pending upgrades here immediately. - Documented the hook in the README under "Dependency freshness gate".
π§ Notes & Reflections¶
- Deliberate scope choice: this checks latest-stable sync, not reproducibility
(
uv sync --locked/--frozenremain available where pinning matters). For an internal repo that treats breakage as discoverable, always-fresh is the right default. - The hook is for humans pushing, not CI β CI still runs the real checks.
Git hook paths don't travel with clones (
core.hooksPathis local config), so the one-timegit config core.hooksPath .githooksafter a fresh clone is the step to remember. - Two copies of the hook now exist (vibes monorepo and this repo). Fine at ~40 lines, but if a third repo adopts it, promote it to a shared script or bake it into the template instead of copying.
π Related¶
uvlockfile model:uv lock,uv sync,uv lock --upgrade,uv sync --locked/--frozen
β³ MaΓ±ana¶
- Next stop (not today): add the hook to the GitHub Template Repo so new modules get it from birth instead of by hand-copying.
- Possibly work the dep-freshness check into a deployment/CI pipeline instead of (or alongside) the hook β useful when enforcement-grade coverage is needed (bots, agents, other contributors pushing without local hooks).
- Remember
git config core.hooksPath .githookson fresh clones of both this repo and the vibes monorepo β the setting is local per clone.