chore(apm): pin apm with uv #520

Merged
Defame1297 merged 1 commits from chore/517-apm-uv into main 2026-12-05 20:32:44 +00:00
Owner

What and why

Closes #517

apm is now pinned at 0.39.3 in pyproject.toml and uv.lock, and run as uv run --frozen apm. Before this, a contributor got whatever apm was installed on their machine. apm-cli leaves requirements-dev.txt and its lock, so this is the only pin.

After merging, in every existing clone:

  1. Run scripts/dev-setup.sh if you have not since #519. Otherwise the next step removes the tools the git hooks use.
  2. Run uv sync --frozen, then uv run --frozen apm install.
  3. If the install stops with "Kept .claude/commands/plan.md" (or ship.md), move both files aside and install again.

The merge publishes a new ci image version, because requirements-dev.* and images/ci/Dockerfile are inputs of that image. The change only removes packages from it. Estimated compressed size of the /opt/venv layer: about 52 MB, under the 100 MB limit.

Renovate does not update the new pin until #518.

Verified

  • uv lock --check passes, and uv run --frozen apm --version prints 0.39.3.
  • With no other apm on PATH, uv run --frozen apm install and uv run --frozen apm audit succeed, and the audit reports no drift.
  • After that install, .claude/commands/plan.md and .claude/commands/ship.md contain disable-model-invocation: true. Neither file is tracked.
  • uv sync --frozen leaves .venv-dev unchanged, and pre-commit run --all-files passes afterwards.
  • requirements-dev.lock loses 40 packages, and no other version changes.
  • apm.lock.yaml changes only in its timestamp, the apm version and the hashes of plan.md and ship.md.
  • python3 -m unittest discover -s tests/scripts: 335 tests pass.
  • A built Collection passes scripts/check_tarball.py and contains neither new file.
  • renovate --platform=local --dry-run=lookup at 44.161.0 runs cleanly with the changed renovate.json.
  • ansible-test sanity: passed in the pre-push hook.

Not verified

  • The ci image was not built locally.
  • uv sync --frozen over an old .venv that still holds the dev tools.
  • uv versions other than 0.11.24, 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 #517 apm is now pinned at 0.39.3 in `pyproject.toml` and `uv.lock`, and run as `uv run --frozen apm`. Before this, a contributor got whatever apm was installed on their machine. `apm-cli` leaves `requirements-dev.txt` and its lock, so this is the only pin. **After merging, in every existing clone:** 1. Run `scripts/dev-setup.sh` if you have not since #519. Otherwise the next step removes the tools the git hooks use. 2. Run `uv sync --frozen`, then `uv run --frozen apm install`. 3. If the install stops with "Kept .claude/commands/plan.md" (or `ship.md`), move both files aside and install again. The merge publishes a new `ci` image version, because `requirements-dev.*` and `images/ci/Dockerfile` are inputs of that image. The change only removes packages from it. Estimated compressed size of the `/opt/venv` layer: about 52 MB, under the 100 MB limit. Renovate does not update the new pin until #518. ## Verified - `uv lock --check` passes, and `uv run --frozen apm --version` prints 0.39.3. - With no other `apm` on `PATH`, `uv run --frozen apm install` and `uv run --frozen apm audit` succeed, and the audit reports no drift. - After that install, `.claude/commands/plan.md` and `.claude/commands/ship.md` contain `disable-model-invocation: true`. Neither file is tracked. - `uv sync --frozen` leaves `.venv-dev` unchanged, and `pre-commit run --all-files` passes afterwards. - `requirements-dev.lock` loses 40 packages, and no other version changes. - `apm.lock.yaml` changes only in its timestamp, the apm version and the hashes of `plan.md` and `ship.md`. - `python3 -m unittest discover -s tests/scripts`: 335 tests pass. - A built Collection passes `scripts/check_tarball.py` and contains neither new file. - `renovate --platform=local --dry-run=lookup` at 44.161.0 runs cleanly with the changed `renovate.json`. - `ansible-test sanity`: passed in the pre-push hook. ## Not verified - The `ci` image was not built locally. - `uv sync --frozen` over an old `.venv` that still holds the dev tools. - uv versions other than 0.11.24, 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 22:22:17 +00:00
chore(apm): pin apm with uv
Build / build (pull_request) Successful in 28s
Molecule / select (pull_request) Successful in 5s
Lint / lint (pull_request) Successful in 4m16s
Molecule / scenarios (pull_request) Successful in 34m33s
Molecule / Result (pull_request) Successful in 1s
595f517b49
A bare `apm` is whatever version a machine has. apm 0.37.0 to 0.39.1
refuse an apm.lock.yaml rewritten by 0.39.2 or later, and versions before
0.39.0 drop `disable-model-invocation` from the deployed Claude commands.
uv now runs one pinned version, from a .venv of its own.

apm-cli leaves requirements-dev.txt, so there is one pin. Its lock loses 40
packages and no other version moves. apm.lock.yaml is regenerated with the
pinned apm.

Refs: #517
Assisted-by: Claude Code
CODEOWNERS rules requested review from Defame1297 2026-12-04 22:22:17 +00:00
Defame1297 scheduled this pull request to auto merge when all checks succeed 2026-12-05 20:32:37 +00:00
Defame1297 approved these changes 2026-12-05 20:32:43 +00:00
Defame1297 merged commit 535926b36e into main 2026-12-05 20:32:44 +00:00
Defame1297 deleted branch chore/517-apm-uv 2026-12-05 20:32:44 +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#520