Phase 2: Repair local validation hooks (#605) #606

Merged
erikinkinen merged 1 commit from phase2/bug-605-local-hooks into main 2026-10-20 15:32:30 +02:00
Owner

Task

Closes #605

Summary

The local Markdown hook selected Ruby markdownlint with a missing .markdownlint.yaml, while CI used the Node.js CLI and .markdownlint.json. Development setup also relied on a system/user Python install, leaving the installed hook unable to import pre_commit on this checkout.

Install both hook types from an ignored .venv-dev environment. Pin pre-commit 4.7.0 and use markdownlint-cli 0.45.0 with the existing JSON configuration in both hooks and CI. Document setup and explicit push-stage validation.

Scope

Development setup, Markdown hook/CI parity, and usage documentation. No simulator semantics or research protocol changes.

Design intent

The generated hook points to the isolated interpreter, so activation and system Python packages are unnecessary. Preserve all existing hygiene and C++ formatting checks.

Phase discipline

Tooling defect found while implementing P2-01 (#84); Phase 2 milestone. This PR is dedicated to issue #605.

Verification

  • bash tools/dev-setup.sh: passed in a separate checkout of the baseline plus this fix.
  • .venv-dev/bin/pre-commit run --all-files: all eight hooks passed.
  • .venv-dev/bin/pre-commit run --all-files --hook-stage pre-push: all eight hooks passed.
  • Actual commit and push hooks passed with no bypass; git verify-commit HEAD verified the signed commit.
  • Forgejo CI must pass for the PR head before merge.
# Task Closes #605 ## Summary The local Markdown hook selected Ruby markdownlint with a missing `.markdownlint.yaml`, while CI used the Node.js CLI and `.markdownlint.json`. Development setup also relied on a system/user Python install, leaving the installed hook unable to import `pre_commit` on this checkout. Install both hook types from an ignored `.venv-dev` environment. Pin pre-commit 4.7.0 and use markdownlint-cli 0.45.0 with the existing JSON configuration in both hooks and CI. Document setup and explicit push-stage validation. ## Scope Development setup, Markdown hook/CI parity, and usage documentation. No simulator semantics or research protocol changes. ## Design intent The generated hook points to the isolated interpreter, so activation and system Python packages are unnecessary. Preserve all existing hygiene and C++ formatting checks. ## Phase discipline Tooling defect found while implementing P2-01 (#84); Phase 2 milestone. This PR is dedicated to issue #605. ## Verification - `bash tools/dev-setup.sh`: passed in a separate checkout of the baseline plus this fix. - `.venv-dev/bin/pre-commit run --all-files`: all eight hooks passed. - `.venv-dev/bin/pre-commit run --all-files --hook-stage pre-push`: all eight hooks passed. - Actual commit and push hooks passed with no bypass; `git verify-commit HEAD` verified the signed commit. - Forgejo CI must pass for the PR head before merge.
erikinkinen added this to the Phase 2 milestone 2026-10-20 15:29:04 +02:00
Phase 2: Repair local validation hooks (#605)
All checks were successful
markdownlint / markdown-lint (pull_request) Successful in 12s
clang-format / check-format (pull_request) Successful in 15s
ci / smoke (pull_request) Successful in 2m32s
markdownlint / markdown-lint (push) Successful in 18s
clang-format / check-format (push) Successful in 19s
ci / smoke (push) Successful in 2m18s
7180a44d06
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
erikinkinen/AES!606
No description provided.