Repository navigation
feat(roadmap): run the project hooks and scoped CI in the Job - #3112
Conversation
…#3043) The scoped tests check runs the test modules that cover the changed files, and only the changed test modules above 30. It does not run when no test covers the change. Every hook run reads a copy of the configuration of the default branch. A hook run that runs out of time is a failure that no repair fixes. An error in the scoped phase pushes nothing. A failed check after the push gets bounded repair rounds, with a comment for each.
|
Test results and review findings for #3043. Fail-to-pass: Full Time of the scoped tests check on 2 CPUs ( Findings fixed:
Findings not fixed: none. |
# Conflicts: # README.md # docs/CLI_REFERENCE.md # docs/commands/roadmap.md # openspec/specs/roadmap-implement-runner/spec.md # openspec/specs/roadmap-implement-step/spec.md # src/devops_cli/ai/tasks/roadmap_implement_step.md # tests/roadmap/test_roadmap_implement_prompt.py
…3115) ## What changes The test `test_a_hostile_agents_md_is_data_and_never_changes_the_instructions` compares `inputs.instructions` with `fill_prompt(load_task_prompt("roadmap_implement_step.md"))`. It compared with the raw prompt, which #3111 stopped returning when it made `build_step_inputs` fill the two table placeholders. The merge of #3107 and #3111 left the required check Tests & Coverage red on `main`. ## Why A red `main` blocks every open pull request, such as #3112. The test still proves its rule: a hostile `AGENTS.md` leaves the instructions unchanged. ## Verification - Before: `uv run pytest tests/roadmap/test_roadmap_implement_step_rules.py -k hostile -n0` on `origin/main` fails with `(False, True, True)`. - After: the same file passes (11 tests). Closes #3114
🤖 I have created a release *beep* *boop* --- ## [0.38.0](v0.37.4...v0.38.0) (2026-11-01) ### Features * **review:** osv-scanner toolrun records its database digest ([#3120](#3120)) ([5731fac](5731fac)) * **roadmap:** add gate tools to the runner, one shell policy ([#3111](#3111)) ([7735d8b](7735d8b)), closes [#3072](#3072) * **roadmap:** give the step AGENTS.md and routed rules ([#3107](#3107)) ([80a22eb](80a22eb)), closes [#3097](#3097) * **roadmap:** run the project hooks and scoped CI in the Job ([#3112](#3112)) ([b7ab211](b7ab211)), closes [#3043](#3043) ### Bug Fixes * **ai:** send the per-call sampling of LLMClient.chat ([#3126](#3126)) ([8207bdc](8207bdc)) * **argo:** replace a token that Argo CD refuses ([#3121](#3121)) ([b4955b4](b4955b4)) * **devcontainer:** remove CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC ([#3125](#3125)) ([295c32c](295c32c)) * **k8s:** set q8_0 KV cache on every Ollama tier ([#3101](#3101)) ([aad0115](aad0115)) * **rag:** raise EmbeddingsError for an empty Ollama URL list ([#3118](#3118)) ([111a031](111a031)) * **security:** refuse PYTEST_ADDOPTS and npm_config_logs_dir overrides ([#3119](#3119)) ([9fe2af5](9fe2af5)) ### Code Refactoring * **security:** read legacy numeric hosts with getaddrinfo ([#3128](#3128)) ([41779f9](41779f9)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: dan-petty-release[bot] <346998822+dan-petty-release[bot]@users.noreply.github.com>
|
Advisory pre-merge review (automated; a person decides). Recommendation: hold. One major finding is proven: a Job item that changes a workflow cannot pass the scoped pre-push check. The PR is already merged (b7ab211), so a follow-up fix is needed.
Nits, not findings: the archived proposal and Weighing of the lens results: the correctness finding (row 1) is kept as major because I reproduced the failing row and read the hook and the image rules. The test, fidelity and standards findings are kept at minor. Fidelity criterion 2 (a shared module runs only the changed test modules) is stated in the proposal and the design, so I drop it. No lens found a secret leak, a swallowed error or test-detecting code. Checks that I ran:
|
## What changes The Job leaves out of its hook configuration any hook whose program the runner image does not hold. Today that is `devops-ci-workflows-pre-push`, which runs `actionlint`. The checks of the pull request run it. - `runner_tools.py`: `HOOK_PROGRAMS` (hook id to programs) and `hooks_without_programs()`. - `implement_hooks.py`: `trusted_config` drops those hooks from the copy it writes for every hook run, and a repository that keeps no hook. The copy is the same text when nothing is dropped. - Tests: the copy without the hook, the copy with the program on PATH, a repository with no hook left, the search-path check, and a check that each skipped hook is in `.pre-commit-config.yaml` and each program is in `NOT_IN_RUNNER`. ## Why #3111 left `actionlint` out of the runner image, and #3112 made the Job run the hooks of the `pre-push` stage. So an item that changes a workflow file failed that hook in the Job, no agent could repair it, and the Job stopped with no push. The independent review of #3112 proved the failure. ## Verification - `pre-commit validate-config` accepts the repository configuration with that hook removed (17 of 18 hooks stay). - `uv run devops ci test tests/roadmap` and the invariant tests pass (2642 tests). Closes #3136
The runner Job now runs the checks that a person runs in the devcontainer. It uses the same definitions.
.pre-commit-config.yamlas a child with no GitHub token. It installs no git hook. Every run reads a copy of the configuration of the default branch, so an edit of the agent skips no hook.pre-commitstage as an exit check. A failed hook goes to the agent as a repair turn. The settingroadmap.implement.repair_rounds(default 3) bounds all repair turns.pre-pushstage, the static rows ofdevops ci, and the tests that cover the changed files. The tests check stays small: above 30 test modules it runs only the changed test modules, and it does not run when no test covers the change. The Job pushes only a head that passed. Any stop in this phase pushes nothing.actionlintandzizmorhooks run on a push only when the push changes a workflow.The change is
openspec/changes/archive/2026-11-01-3043-runner-hooks-and-scoped-ci/.Closes #3043