chore(dev): move the dev tools from .venv to .venv-dev #519

Merged
Defame1297 merged 1 commits from chore/516-venv-dev into main 2026-12-04 21:16:59 +00:00
Owner

What and why

Closes #516

scripts/dev-setup.sh now installs the contributor tools into .venv-dev, and the git hooks run from there. This frees .venv for uv, which will pin apm (#517): uv sync removes every package that is not in its lock, so it would remove the tools the hooks need.

After merging, re-run scripts/dev-setup.sh in every existing clone, before #517 lands. Until then its hooks keep using .venv. The script leaves the old .venv in place.

The comments in requirements-dev.txt and images/ci/Dockerfile still say .venv. Both files are inputs of the ci image, so #517 updates them together with its own change to that image.

Verified

  • scripts/dev-setup.sh in a fresh clone: creates .venv-dev and no .venv. pre-commit run --all-files passes with the tools from .venv-dev/bin.
  • scripts/dev-setup.sh from main, then from this branch, in one clone: all three hooks move from .venv/bin to .venv-dev/bin. The new test for this fails against the old script.
  • With both directories present: git status is clean, and scripts/check_tarball.py passes on a built Collection that contains neither.
  • python3 -m unittest discover -s tests/scripts: 334 tests pass.
  • ansible-test sanity: passed in the pre-push hook.

Not verified

  • A real uv sync next to .venv-dev; #517 covers it.
  • Linked worktrees and macOS.
  • Molecule was not run locally.

  • I confirm third-party material is recorded in NOTICE and REUSE.toml, or there is none.

Assisted-by: Claude Code

## What and why Closes #516 `scripts/dev-setup.sh` now installs the contributor tools into `.venv-dev`, and the git hooks run from there. This frees `.venv` for uv, which will pin apm (#517): `uv sync` removes every package that is not in its lock, so it would remove the tools the hooks need. **After merging, re-run `scripts/dev-setup.sh` in every existing clone, before #517 lands.** Until then its hooks keep using `.venv`. The script leaves the old `.venv` in place. The comments in `requirements-dev.txt` and `images/ci/Dockerfile` still say `.venv`. Both files are inputs of the `ci` image, so #517 updates them together with its own change to that image. ## Verified - `scripts/dev-setup.sh` in a fresh clone: creates `.venv-dev` and no `.venv`. `pre-commit run --all-files` passes with the tools from `.venv-dev/bin`. - `scripts/dev-setup.sh` from `main`, then from this branch, in one clone: all three hooks move from `.venv/bin` to `.venv-dev/bin`. The new test for this fails against the old script. - With both directories present: `git status` is clean, and `scripts/check_tarball.py` passes on a built Collection that contains neither. - `python3 -m unittest discover -s tests/scripts`: 334 tests pass. - `ansible-test sanity`: passed in the pre-push hook. ## Not verified - A real `uv sync` next to `.venv-dev`; #517 covers it. - Linked worktrees and macOS. - Molecule was not run locally. --- - [x] I confirm third-party material is recorded in `NOTICE` and `REUSE.toml`, or there is none. Assisted-by: Claude Code
Claude added 1 commit 2026-12-04 21:13:22 +00:00
chore(dev): move the dev tools from .venv to .venv-dev
Build / build (pull_request) Successful in 34s
Molecule / select (pull_request) Successful in 3s
Molecule / scenarios (pull_request) Skipped
Molecule / Result (pull_request) Successful in 1s
Lint / lint (pull_request) Successful in 1m49s
f62097a748
uv uses .venv as its project environment, and `uv sync --frozen` removes
every package that is not in uv.lock. The tools the git hooks need would
go with it, so they get a directory of their own.

Re-running scripts/dev-setup.sh switches the hooks of an older clone and
leaves its .venv alone. Ignore rules and prunes cover both directories.

Refs: #516
Assisted-by: Claude Code
CODEOWNERS rules requested review from Defame1297 2026-12-04 21:13:22 +00:00
Defame1297 approved these changes 2026-12-04 21:16:55 +00:00
Defame1297 merged commit d732ac0a71 into main 2026-12-04 21:16:59 +00:00
Defame1297 deleted branch chore/516-venv-dev 2026-12-04 21:16:59 +00:00
Sign in to join this conversation.
No Reviewers
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Mortis/Kamino#519