You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
ci: overengineering audit of CI gates and hooks #5683
Run /overengineering:audit over this repo's CI (ci.yml and the scripts/check-*.sh gates) and hooks, and retire what no longer earns its keep. Include the audit-instructions catalog's per-model version tokens, which need hand widening on every model release.
Follow-on from the Sonnet 5.5 prompting-guide work (plan: docs/topics/sonnet-5-5-prompting-digest/PLAN.md on branch feat/sonnet-5-5-prompting-digest), after its PR merges.
Routing reason: the done-when retires enforcement (CI gates and hooks). /overengineering:realign gates every retirement on a per-item human acceptance, and guards change only on the operator's say-so, so no autonomous lane can finish this item. The audit half is read-only and can be run by anyone, but stopping there would narrow the stated outcome.
No prior issue or ledger entry covers an overengineering audit of this repository's own CI gates and hooks; no docs/out-of-scope/ concept matches.
The version-token item is a design change, not a retirement. The audit-instructions catalog matches a model scope by exact string equality of the normalized version token, so every model release needs its rows widened by hand. Replacing that needs a matching rule, which is separate from deciding whether a gate earns its keep.
Basis: verified, plugins/harness-config/skills/audit-instructions/reference/criteria.md:123.
Work class: structural. Retiring CI gates and hooks is cross-cutting across every plugin's enforcement surface. Basis: judgment.
Agent Brief
Type: Task Summary: Audit this repository's CI gates and hooks for enforcement that no longer earns its keep, and retire what the operator accepts.
Current behavior:
The CI workflow, the check-* gate scripts, and the plugin hooks have grown without a whole-surface keep-or-retire review. The audit-instructions catalog's per-model rows need hand widening on every model release.
Desired behavior:
An /overengineering:audit report covers the CI workflow, the gate scripts, and the hooks. Each finding the operator accepts is retired through /overengineering:realign on its rollback ladder (config-disable first, observe, delete last). The version-token widening has a proposed replacement that removes the per-release hand edit.
Key interfaces:
The overengineering audit and realign skills, and their per-item human gate.
The audit-instructions catalog's model-scope matching on the normalized version token.
Acceptance criteria:
An audit report covering the CI workflow, every gate script, and the hooks is posted on this issue.
Each accepted retirement is applied through realign, with the operator's acceptance recorded per item.
A proposal for model-scope matching that needs no hand edit on a model release is posted, or the hand edit is justified as earning its keep.
Out of scope:
Proposing new automation.
Retiring any security-class guard without explicit operator approval.
Audit half done (Attended Build, 2026-10-20, read-only /overengineering:audit; findings artifact is local to the owner's machine). Scope: hooks, the CI lanes in pr-require-checks.yml (there is no ci.yml), and the 53 scripts/check-*.sh gates. Evidence windows were short (about 10 days of hook logs, about 2.3 hours of CI runs), so most verdicts are "not proven either way".
Candidates, each waiting on the owner's per-item acceptance through /overengineering:realign (nothing has been switched off):
Retire: source-control's pr-body-linkage-gate. It probes .github/actions/pr-contract, which this repo doesn't have, so it never runs here.
Retire: the Linux "drive-root scan is a no-op" CI step. Downgrade: the check-skills report-only steps.
Flag for human: pr-check-managed-files-hosted.yml duplicates the required check-managed-files job (synced from standards).
Flag for human: disk-hygiene's destructive guard (648 of 649 denies on not-exact-engine-command, mostly reads of its own source).
Flag for human: guardrails block-dangerous-git and block-root-delete-target (mostly scratch-tree blocks). Narrow both matchers.
Proposed 30-day trial off: block-convention-violation (133,670 runs, 0 blocks; ci-status already checks titles) and block-noncanonical-commit. Both are user-scope settings, so this is the owner's call.
Version tokens: keep exact-match. In #7013, 10 of 13 rows got a dated decline, so a prefix rule would have armed them wrongly. The removable work is finding which rows need a decision. That is new automation, routed to /harness-config:audit-automation-gaps.
guardrails, disk-hygiene: narrow three destructive-guard matchers to their measured false positives #9779: narrow the disk-hygiene destructive guard's Bash(*hygiene.py*) filter to engine invocations. Narrow block-dangerous-git to allow reset --hard/clean -f in temp-dir repositories, and teach block-root-delete-target to resolve a same-command literal assignment. Each change ships with a stay-quiet test and a still-blocks test.
Not sliced, and waiting on the owner:
pr-body-linkage-gate: the audit marked it for retirement because it never runs here. Its scope guard looks for .github/actions/pr-contract, and the standards rename map (components/github-actions-conventions/rename-map.json) records that action renamed to .github/actions/pr-require-checks/check-contract. So the gate is dead fleet-wide because it still looks for the old name. Repointing it is the alternative to retiring it.
The 30-day trial-off of block-convention-violation (0 blocks in 133,670 runs) and of block-noncanonical-commit (79 blocks, almost all multi-line git commit -m). Both are user-scope settings.
pr-check-managed-files-hosted.yml duplicates the required check-managed-files job. It is synced from standards, so it is not sliced here.
Version tokens stay exact-match, as the audit concluded.
Owner decision Q101 (2026-10-24): block-convention-violation is off for a 30-day trial on every fleet machine; block-noncanonical-commit stays on.
Settings change: melodic-software/dotfiles#1312 sets pluginConfigs."guardrails@melodic-software".options.block_convention_gate_enabled to false. Applied on one WSL machine; the rest get it on the next fleet-converge.
On or after 2026-11-23: compare title-check failures in ci-status during the trial with before; keep block_convention_gate_enabled off if none rose, else restore it.
Refinement. A read-only run explored this repository, searched its issues and pull requests, and read the allowed docs to draft what follows. On an issue a listed human filed, it counts as the issue's spec once posted, while unedited; it is still model text, so check it.
Intended outcome: The audit is done and the retirements are split into #9777 and #9779; this issue is left with owner decisions on pr-body-linkage-gate, the noncanonical-commit trial and the managed-files duplicate.
Dependencies
#9777: retires the description-voice gate, the drive-root no-op step and the default listing-budget report
#9779: narrows the disk-hygiene, block-dangerous-git and block-root-delete-target matchers
Should this issue be closed as superseded by #9777 and #9779, with the owner-only leftovers tracked separately?
RECOMMENDED: Yes. Close it once both sub-issues are filed, and move the leftovers to their own issues or the owner's list. Basis: judgment
Should pr-body-linkage-gate be repointed at .github/actions/pr-require-checks/check-contract or retired?
RECOMMENDED: Repoint it if the fleet still wants the PR-body linkage check. The 2026-10-24 comment says the rename map records the action as renamed, so the gate looks for an old name. Retire it only if the pr-contract step in ci-status already covers the same check. Basis: context.json comment 2026-10-24 (rename-map.json) and .base/.claude/rules/pr-body-contract.md:3
Should block-noncanonical-commit get a 30-day trial off?
RECOMMENDED: No. The owner's decision Q101 (2026-10-24) keeps it on, so close this item. Basis: context.json comment of 2026-10-24T16:52:12Z
Should the pr-check-managed-files-hosted.yml duplicate of the required check-managed-files job be handled here?
RECOMMENDED: No. It is synced from standards, so raise it in the standards repository. Basis: context.json comment of 2026-10-24T16:43:28Z
Is the version-token item settled as keep exact-match, with the finder for rows needing a decision routed to /harness-config:audit-automation-gaps?
RECOMMENDED: Yes. The criteria.md rule matches model scope by exact version token, and the audit found a prefix rule would have armed 10 of 13 rows wrongly in #7013. Record the justification and drop the item. Basis: plugins/harness-config/skills/audit-instructions/reference/criteria.md:124 and context.json comment of 2026-10-20
Sources read
/home/runner/work/_temp/refine-data/context.json: owner comments of 2026-10-20 and 2026-10-24 record the audit result, the split into #9777 and #9779, and decision Q101
plugins/harness-config/skills/audit-instructions/reference/criteria.md:124: model scope is annotated per version and fires on the resolved target
/home/runner/work/claude-code-plugins/claude-code-plugins/.base/.claude/rules/pr-body-contract.md:3: the pr-contract step inside ci-status fails a pull request on a PR-body contract
Automated refinement by the lanes App. Answer with a comment whose first line is **Decision recorded.**.
Recording the answer to the open question. The label stays: this split parent waits on its open sub-issues, and admission currently refuses it as "split pending" though the split exists, a defect reported to the admission owner.
The refinement asks whether to repoint or retire pr-body-linkage-gate. Owner rule C12 answers it: only an intent mismatch at build or a security issue at review stops work. The PR-body section and linkage contract is advisory (.claude/rules/pr-body-contract.md), so a hook that blocks on it is a gate C12 removes. The negated-closer block is different: it prevents a wrong close that CI only warns on, so it stays. block-noncanonical-commit stays on (owner Q101). This hook work is not in #9777 or #9779; it is this issue's own remaining work:
pr-body-linkage-gate.sh and pr-linkage-mcp-gate.sh detect the renamed pr-require-checks/check-contract step, with tests that fail before the fix.
Both hooks block only a negated closing reference. A body missing a section or linkage passes, with stay-quiet tests, and the README rows and changelog say so.
Decision recorded. The owner answered in the Refinement session (2026-10-25), deciding the open items below on the facts:
go with whatever the facts/data/metrics + /discovery:research says and ensure we're aligned with SOLID, DRY/SSOT principles
I should only ever be in the loop ONLY when necessary (intent/vision changed, something came up during implementation that impacts trajectory/alignment, OR a high security risk) - I've covered this all before
Owner decision Q101 (2026-10-24): block-convention-violation is off for a 30-day trial on every fleet machine; block-noncanonical-commit stays on.
Issue Triage sweep, Q33 (.work/issue-triage-owner-sweep-1/interview-checklist.md:58) is deferred ("outside the pipeline focus; issue not touched") and decides nothing.
This issue is a split parent. #9777 is closed and #9779 is open. The refinement's questions (#5683 (comment)):
Repoint or retire pr-body-linkage-gate?
Decided: the repoint is already on main. Both hooks match the renamed step: gate_re at plugins/source-control/hooks/pr-body-linkage-gate.sh:188 and pr-linkage-mcp-gate.sh:204. Tests cover both: pr-body-linkage-gate.test.sh:581 and pr-linkage-mcp-gate.test.sh:49-53. This repository wires the step at .github/workflows/pr-require-checks.yml:3726. What remains is a mismatch with CI. The hooks block a body that lacks a section or a closing line (plugins/source-control/hooks/pr-linkage-validator.sh:462-480). CI treats that contract as advisory: "The body contract is advisory, reported by comment and the needs-issue-linkage label" (.claude/rules/pr-body-contract.md:7-8). So the hooks block only the negated closing reference. GitHub still closes the issue on that line ("GitHub's negation-blind parser would still close on merge", pr-body-linkage-gate.sh:23-24), and CI does not fail on it (.claude/rules/pr-body-contract.md:3-6). This narrows an authoring-quality hook to match CI. It touches no token, grant, hold or review requirement, so it is not a security boundary. Precedent: fix(source-control): make the PR body gate agree with CI on code-only sections #6270 made this hook agree with CI on code-only sections (commit dc8b50b).
Trial block-noncanonical-commit off?
Decided: no. Q101 keeps it on.
Handle the pr-check-managed-files-hosted.yml duplicate here?
Decided: no. The 2026-10-24 split comment says the file is synced from standards, so this repository does not change it.
pr-body-linkage-gate.sh and pr-linkage-mcp-gate.sh exit 2 only for a negated closing reference (does not close #N). A body missing a contract section or a closing line exits 0. Each change has a stay-quiet test that fails before the fix, and the negated-closer block tests still pass. The change is confined to what the two hooks block on: linkage::section_problems and the pull-request skill's pre-create check that shares it (pr-linkage-validator.sh:438-441) are unchanged.
The source-control README text for both hooks (plugins/source-control/README.md, section pr-body-linkage-gate at :172) and a changelog fragment say the hooks block only a negated closing reference.
On or after 2026-11-23, the date the Q101 decision sets: compare ci-status title-check failures during the trial with the period before it. If they did not rise, keep block_convention_gate_enabled off. If they rose, restore it (melodic-software/dotfiles#1312 holds the setting).
Closing as completed. The 2026-10-27 decision sets the close condition as "#5683 closes when #9779 and the two items above are done", and all three hold. Checked against origin/main at 2e4f59b9b8.
plugins/source-control/hooks/pr-body-linkage-gate.sh:283-288 and pr-linkage-mcp-gate.sh:293-300 exit 2 only when linkage::blocking_problems fails. pr-linkage-validator.sh:496-500 fills that verdict from linkage::scan_body, which reports only a negated closer.
The one open sub-issue, #10794, is outside that condition: it is the host-run comparison of ci-status title-check failures after the Q101 trial, listed apart from the acceptance criteria, due on or after 2026-11-23. It stays open and carries that work.
Activity
feat(playbooks): apply the Sonnet 5.5 prompting guide across the mark…
feat(playbooks): apply the Sonnet 5.5 prompting guide across the mark…
kyle-sexton commentedon Oct 4, 2026
This was generated by AI during triage.
Triage: human-gated
Routing reason: the done-when retires enforcement (CI gates and hooks).
/overengineering:realigngates every retirement on a per-item human acceptance, and guards change only on the operator's say-so, so no autonomous lane can finish this item. The audit half is read-only and can be run by anyone, but stopping there would narrow the stated outcome.What triage established
docs/out-of-scope/concept matches.Basis: verified,
plugins/harness-config/skills/audit-instructions/reference/criteria.md:123.Agent Brief
Type: Task
Summary: Audit this repository's CI gates and hooks for enforcement that no longer earns its keep, and retire what the operator accepts.
Current behavior:
The CI workflow, the
check-*gate scripts, and the plugin hooks have grown without a whole-surface keep-or-retire review. The audit-instructions catalog's per-model rows need hand widening on every model release.Desired behavior:
An
/overengineering:auditreport covers the CI workflow, the gate scripts, and the hooks. Each finding the operator accepts is retired through/overengineering:realignon its rollback ladder (config-disable first, observe, delete last). The version-token widening has a proposed replacement that removes the per-release hand edit.Key interfaces:
Acceptance criteria:
Out of scope:
kyle-sexton commentedon Oct 20, 2026
Audit half done (Attended Build, 2026-10-20, read-only
/overengineering:audit; findings artifact is local to the owner's machine). Scope: hooks, the CI lanes inpr-require-checks.yml(there is noci.yml), and the 53scripts/check-*.shgates. Evidence windows were short (about 10 days of hook logs, about 2.3 hours of CI runs), so most verdicts are "not proven either way".Candidates, each waiting on the owner's per-item acceptance through
/overengineering:realign(nothing has been switched off):scripts/check-skill-description-voice.sh. Nothing calls it (fix(scripts): harden audit-flagged gates and the eval-coverage scanner #5339 said "Not wired into CI"), and 4 of 373 descriptions fail it today.pr-body-linkage-gate. It probes.github/actions/pr-contract, which this repo doesn't have, so it never runs here.pr-check-managed-files-hosted.ymlduplicates the requiredcheck-managed-filesjob (synced from standards).not-exact-engine-command, mostly reads of its own source).Version tokens: keep exact-match. In #7013, 10 of 13 rows got a dated decline, so a prefix rule would have armed them wrongly. The removable work is finding which rows need a decision. That is new automation, routed to
/harness-config:audit-automation-gaps.kyle-sexton commentedon Oct 24, 2026
This was generated by AI while splitting waiting issues into lane-ready slices (owner decisions C12, Q93-Q95, 2026-10-24).
Split into two parallel sub-issues, both from the 2026-10-20 audit:
scripts/check-skill-description-voice.shand the Linux drive-root no-op step. Delete the default-consumer listing-budget report, and run the configured-fraction tripwire only on the schedule.Bash(*hygiene.py*)filter to engine invocations. Narrowblock-dangerous-gitto allowreset --hard/clean -fin temp-dir repositories, and teachblock-root-delete-targetto resolve a same-command literal assignment. Each change ships with a stay-quiet test and a still-blocks test.Not sliced, and waiting on the owner:
pr-body-linkage-gate: the audit marked it for retirement because it never runs here. Its scope guard looks for.github/actions/pr-contract, and the standards rename map (components/github-actions-conventions/rename-map.json) records that action renamed to.github/actions/pr-require-checks/check-contract. So the gate is dead fleet-wide because it still looks for the old name. Repointing it is the alternative to retiring it.block-convention-violation(0 blocks in 133,670 runs) and ofblock-noncanonical-commit(79 blocks, almost all multi-linegit commit -m). Both are user-scope settings.pr-check-managed-files-hosted.ymlduplicates the requiredcheck-managed-filesjob. It is synced from standards, so it is not sliced here.kyle-sexton commentedon Oct 24, 2026
Owner decision Q101 (2026-10-24):
block-convention-violationis off for a 30-day trial on every fleet machine;block-noncanonical-commitstays on.Settings change: melodic-software/dotfiles#1312 sets
pluginConfigs."guardrails@melodic-software".options.block_convention_gate_enabledtofalse. Applied on one WSL machine; the rest get it on the nextfleet-converge.4 remaining items
melodic-automation-lanes commentedon Oct 25, 2026
Refinement. A read-only run explored this repository, searched its issues and pull requests, and read the allowed docs to draft what follows. On an issue a listed human filed, it counts as the issue's spec once posted, while unedited; it is still model text, so check it.
Intended outcome: The audit is done and the retirements are split into #9777 and #9779; this issue is left with owner decisions on pr-body-linkage-gate, the noncanonical-commit trial and the managed-files duplicate.
Dependencies
Related work
Open questions
RECOMMENDED: Yes. Close it once both sub-issues are filed, and move the leftovers to their own issues or the owner's list. Basis: judgment
RECOMMENDED: Repoint it if the fleet still wants the PR-body linkage check. The 2026-10-24 comment says the rename map records the action as renamed, so the gate looks for an old name. Retire it only if the pr-contract step in ci-status already covers the same check. Basis: context.json comment 2026-10-24 (rename-map.json) and .base/.claude/rules/pr-body-contract.md:3
RECOMMENDED: No. The owner's decision Q101 (2026-10-24) keeps it on, so close this item. Basis: context.json comment of 2026-10-24T16:52:12Z
RECOMMENDED: No. It is synced from standards, so raise it in the standards repository. Basis: context.json comment of 2026-10-24T16:43:28Z
RECOMMENDED: Yes. The criteria.md rule matches model scope by exact version token, and the audit found a prefix rule would have armed 10 of 13 rows wrongly in #7013. Record the justification and drop the item. Basis: plugins/harness-config/skills/audit-instructions/reference/criteria.md:124 and context.json comment of 2026-10-20
Sources read
Automated refinement by the lanes App. Answer with a comment whose first line is
**Decision recorded.**.kyle-sexton commentedon Oct 26, 2026
This was generated by AI.
Recording the answer to the open question. The label stays: this split parent waits on its open sub-issues, and admission currently refuses it as "split pending" though the split exists, a defect reported to the admission owner.
The refinement asks whether to repoint or retire pr-body-linkage-gate. Owner rule C12 answers it: only an intent mismatch at build or a security issue at review stops work. The PR-body section and linkage contract is advisory (
.claude/rules/pr-body-contract.md), so a hook that blocks on it is a gate C12 removes. The negated-closer block is different: it prevents a wrong close that CI only warns on, so it stays. block-noncanonical-commit stays on (owner Q101). This hook work is not in #9777 or #9779; it is this issue's own remaining work:pr-body-linkage-gate.shandpr-linkage-mcp-gate.shdetect the renamedpr-require-checks/check-contractstep, with tests that fail before the fix.kyle-sexton commentedon Oct 27, 2026
Decision recorded. The owner answered in the Refinement session (2026-10-25), deciding the open items below on the facts:
Owner ledger rows for this issue:
.work/backlog-to-zero/interview-checklist.md:143), also posted on the issue (ci: overengineering audit of CI gates and hooks #5683 (comment)):.work/issue-triage-owner-sweep-1/interview-checklist.md:58) is deferred ("outside the pipeline focus; issue not touched") and decides nothing.This issue is a split parent. #9777 is closed and #9779 is open. The refinement's questions (#5683 (comment)):
Decided: no. The pr-body-linkage-gate work below is in neither sub-issue, so this issue keeps it and closes when it and guardrails, disk-hygiene: narrow three destructive-guard matchers to their measured false positives #9779 are done.
pr-body-linkage-gate?Decided: the repoint is already on main. Both hooks match the renamed step:
gate_reatplugins/source-control/hooks/pr-body-linkage-gate.sh:188andpr-linkage-mcp-gate.sh:204. Tests cover both:pr-body-linkage-gate.test.sh:581andpr-linkage-mcp-gate.test.sh:49-53. This repository wires the step at.github/workflows/pr-require-checks.yml:3726. What remains is a mismatch with CI. The hooks block a body that lacks a section or a closing line (plugins/source-control/hooks/pr-linkage-validator.sh:462-480). CI treats that contract as advisory: "The body contract is advisory, reported by comment and theneeds-issue-linkagelabel" (.claude/rules/pr-body-contract.md:7-8). So the hooks block only the negated closing reference. GitHub still closes the issue on that line ("GitHub's negation-blind parser would still close on merge",pr-body-linkage-gate.sh:23-24), and CI does not fail on it (.claude/rules/pr-body-contract.md:3-6). This narrows an authoring-quality hook to match CI. It touches no token, grant, hold or review requirement, so it is not a security boundary. Precedent: fix(source-control): make the PR body gate agree with CI on code-only sections #6270 made this hook agree with CI on code-only sections (commit dc8b50b).block-noncanonical-commitoff?Decided: no. Q101 keeps it on.
pr-check-managed-files-hosted.ymlduplicate here?Decided: no. The 2026-10-24 split comment says the file is synced from standards, so this repository does not change it.
Decided: they stay exact-match. The 2026-10-20 audit found that in docs(harness-config): add Haiku 5.5 to the audit-instructions per-model sets #7013, 10 of 13 rows got a dated decline, so a prefix rule would have armed them wrongly. No new finder is added under this issue.
Acceptance criteria:
pr-body-linkage-gate.shandpr-linkage-mcp-gate.shexit 2 only for a negated closing reference (does not close #N). A body missing a contract section or a closing line exits 0. Each change has a stay-quiet test that fails before the fix, and the negated-closer block tests still pass. The change is confined to what the two hooks block on:linkage::section_problemsand the pull-request skill's pre-create check that shares it (pr-linkage-validator.sh:438-441) are unchanged.plugins/source-control/README.md, sectionpr-body-linkage-gateat:172) and a changelog fragment say the hooks block only a negated closing reference.Host run (host-run label):
block_convention_gate_enabledoff. If they rose, restore it (melodic-software/dotfiles#1312 holds the setting).kyle-sexton commentedon Oct 31, 2026
Closing as completed. The 2026-10-27 decision sets the close condition as "#5683 closes when #9779 and the two items above are done", and all three hold. Checked against
origin/mainat2e4f59b9b8.plugins/source-control/hooks/pr-body-linkage-gate.sh:283-288andpr-linkage-mcp-gate.sh:293-300exit 2 only whenlinkage::blocking_problemsfails.pr-linkage-validator.sh:496-500fills that verdict fromlinkage::scan_body, which reports only a negated closer.pr-body-linkage-gate.test.sh:151andpr-linkage-mcp-gate.test.sh:110,112. They shipped in fix(source-control): block only a negated closing reference in the PR body linkage hooks #10810. This check did not re-run them.linkage::section_problems(pr-linkage-validator.sh:436), andskills/pull-request/scripts/check-body-sections.shwas not in its diff.plugins/source-control/README.md:173-177and:464-466;plugins/source-control/CHANGELOG.md:395.The one open sub-issue, #10794, is outside that condition: it is the host-run comparison of ci-status title-check failures after the Q101 trial, listed apart from the acceptance criteria, due on or after 2026-11-23. It stays open and carries that work.