Uh oh!
There was an error while loading. Please reload this page.
governance: human merge is the review record — retire the per-PR ADR approval check, add the report-only governed-merges audit - #9523
Merged
Conversation
… review record; add the report-only governed-merges audit Fixes#9495 mechanics (ruling 2026-08-18): the always-red per-PR check retires (workflow + gate script), detection moves to a report-only post-merge audit over the unified governed surface (docs/adr/**, .claude/**, skills/**, AGENTS.md, CLAUDE.md), and the sole pre-merge line of defense is seat discipline, hardened in SKILL.md and AGENTS.md Prime Directive #14. The required-context registry drops its stale 'ADR maintainer approval' row (registry-follows half of the #6865 two-step; Settings half attested on the card). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Rn7aaamsR99FXRqLcpL99q
This was referenced Aug 18, 2026
instruction scan gains the retirement ledger row The modify/delete conflict on scripts/check-adr-merge-approval.mjs resolves as deletion: #9511 widened the per-PR gate's predicate to the published skills/ catalog under the pre-retirement regime, and that semantic content survives in the audit's GOVERNED_SURFACES (skills/** was already governed there by the 2026-08-18 unified definition). The #9504 instruction-surface scan lands intact; per its append-only ledger contract this merge adds the 'ADR maintainer approval' retirement row (replacedBy: null) in the same PR that removes the registry entry. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Rn7aaamsR99FXRqLcpL99q
Contributor
📓 Docs Drift CheckNothing in this diff resolved to a documentable surface (no symbol, route or SDK anchor derived from 0 changed package(s)), so this run has no opinion about the docs. |
This was referenced Aug 18, 2026
…CONTEXT_NAMES The ledger row was edited into the working tree while the merge's index already held the auto-merged file, so the merge commit took the index without it (the MM half-commit shape AGENTS.md warns about — caught by the worktree-removal guard refusing an unclean tree). This commit is that row, nothing else. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Rn7aaamsR99FXRqLcpL99q
hotlong
approved these changes
Aug 18, 2026
hotlong
marked this pull request as ready for review
August 18, 2026 07:31
hotlong
enabled auto-merge
August 18, 2026 07:31
Uh oh!
There was an error while loading. Please reload this page.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes#9495
Merge posture — DRAFT, human merge only, by construction
This PR's own diff touches the governed surface it defines (AGENTS.md,
.claude/skills/**,.github/**enforcement chain), so per the ruling it implements: no AI seat flips it ready, enqueues it, or arms auto-merge. Its own human merge is the first exercise of the new rule (required outcome 4).What this implements (maintainer ruling 2026-08-18, 「同意。」 on the card; scope extension 「同意」 recorded in the card's comments)
.github/workflows/adr-merge-approval.ymlandscripts/check-adr-merge-approval.mjsare deleted; thecheck:adr-merge-approvalpackage script goes with them. No check namedADR maintainer approvalruns on PRs any more.scripts/pm/check-governed-merges.mjs(thecheck-half-statesreport-only precedent): enumerates PRs merged intomainsince a date/ref whose diff touched a governed surface, with merge attribution, for the PM round report. Enumeration and diff paths are pure local git overorigin/main— zero API calls on a clean window; the API is consulted only for attribution (one PR read per governed entry). Exit contract: 0 = sweep complete (entries or none); 1 = cannot sweep; 2 = swept but attribution unresolved (missing token / HTTP failure) — printed loud, never silently clean. Its--self-testis wired into lint.yml beside the half-states step (an uninvoked self-test is the check:react-declaration-parity 是唯一没接进任何 workflow 的源码审计门禁,且无 MANIFEST 时静默 skip 退出 0 —— 它现在永远不可能红 #4690 phantom shape) andcheck:pm-governed-mergesin package.json runs it.docs/adr/**+.claude/**in full +skills/**+ rootAGENTS.md+ rootCLAUDE.md— states that a human merge IS the review record, that seat discipline (never flip ready / enqueue / arm auto-merge on a governed PR) is the sole pre-merge line of defense, and that round reports carry the audit list. The Guardrails ADR + Skills bullets merge into one governed-surface bullet keeping all three ruling quotes verbatim (2026-08-08, 2026-08-11, 2026-08-18). AGENTS.md Prime Directive feat: Comprehensive CRM example demonstrating all ObjectStack protocol features #14's stale sentence — "a required check that stays red unless the maintainer's own account has approved" — is replaced by the new regime (grep-derived; CLAUDE.md has no reference, verified by the same grep).The #6865 two-step, honored
The required-context registry (
scripts/check-required-contexts.mjs) drops itsADR maintainer approvalrow plus the self-test fixtures that read the retired workflow. This is the registry-follows half; the Settings half is the maintainer attestation recorded on the card (comment 5324507114): the maintainer's own 2026-08-18 reading of the required set lists exactly six contexts, this one not among them, confirmed empirically the same day by a PR that merged through the queue while carrying this check atconclusion: failurewith zero approving reviews. A tombstone note in the registry header records the removal so nobody re-enrolls it from git archaeology. Thetypes:-guard fixtures (assertion 7b, #8304) are retargeted from the deleted workflow onto ci.yml so that guard keeps red-direction coverage.Same-day churn absorbed by the merge round (commits 2–3)
origin/mainmoved while this PR was open; the merge commit resolves it under the ruling:skills/catalog is human-merge by convention but is not gated — two of the pm-dispatch fork's three prefixes are enforced #9404) widened the retiring gate's predicate to the publishedskills/catalog — a pre-retirement-regime card landing after the retirement ruling. The modify/delete conflict resolves as deletion; the widening's semantic content is not lost:skills/**is already governed in the audit'sGOVERNED_SURFACESunder the 2026-08-18 unified definition.check-required-contexts.mjs. Its append-onlyRETIRED_CONTEXT_NAMESledger contract requires the PR that removes a registry row to ledger the name — so this PR adds theADR maintainer approvalretirement row (replacedBy: null, no budgets: no instruction surface named it when the row was written; the row is the standing ban on writing the dead name fresh). Merged self-test: 81 assertions green.MMshape AGENTS.md warns about) — caught by the worktree-removal guard refusing an unclean tree at close-out, and landed as its own third commit (bb4d0b4ed, +13 lines, the row alone). The gates always read the working tree, which carried the row throughout; the union below is re-attributed to the head that actually contains it.Institutional memory preserved (required outcome 1's preservation clause)
The retired gate's incident history — the 2026-08-08 double violation within an hour of the ruling, the #8161 identity-proxy unsatisfiability, the #8012 arming incident, the #9238 queue landing with zero reviews — moves into the audit script's header as case law, and its measured violations become executable replay fixtures in the audit's
--self-test. CODEOWNERS keeps routingdocs/adr/, itself, and now the audit script to the maintainer; its header explains the regime change.Boundary decisions, stated
AGENTS.md/CLAUDE.mdonly — notexamples/AGENTS.md, not the create-objectstack template copy (product content). Near misses are pinned in the self-test. Widening to those, or to objectui/cloud, is the separately-filed cross-repo work the card excludes.merged_byattribution was measured, not assumed (the dispatch's mechanism assumption): both observed flows attribute to the human account (a queue-flow landing and a direct merge both readmerged_by: hotlong, 2026-08-18). The header instructs: if a bot login ever appears, report it verbatim and extend to the enqueue timeline actor — never remap silently.docs/adr/**, but the gate it describes now also holds.claude/skills/**#9403 / PR docs(agents): Prime Directive #14 governs three surfaces, and names the register that holds them #9527 — merge-order reconciliation stated on the card, comment 5324955341); the CODEOWNERS skill-surface routing gap stays with finding: CODEOWNERS routes docs/adr/ and the gate's enforcement chain, but neither governed skill surface #9513.SKILL.md ratchet: 682/682, net zero
Additions (ACCEPT-fork surface + sole-defense clause, merged Guardrails bullet, round-report audit line, guards-index row) are paid by cuts whose content survives verbatim elsewhere, each cut site left pointing at the surviving copy:
references/review-checklist.mdCI-convergence bullet (verbatim, with provenance)references/landing-operations.mdsection A (verbatim)references/landing-operations.mdsection B (verbatim)Gates — union re-run at the final head
bb4d0b4ed(git rev-parse --short HEAD from that run; earlier runs at9b75229adand at the tree state now committed asbb4d0b4edwere identical)All exit 0:
check:pm-skill-ratchet(682/682, headroom 0) ·check:pm-skill-id-lint·check:doc-authoring·check:skill-frame-sync·check:doc-formula-expressions(after building the lint closure) ·check:nul-bytes·check:required-contexts(+81-assertion merged self-test; 8 names pinned) ·check:pm-governed-merges(25 assertions) ·check:partof-closing-keyword·check:pm-dispatch-gates(273 cases) ·check:node-version·check:shard-attestation·check:workflow-status-functions·check:pm-half-states(140 cases) ·check:type-check-coverage· docs-audit wrapper self-test (220 cases). Families were re-derived from the actual diff (node scripts/pm/dispatch-gates.mjs, no-args self-derived change set), not recalled.One honest non-reading:
check:type-check-debt --re-measurerefuses to run in this worktree by design (52 workspace deps have no built dist; its own error text mandates the full closure build lint.yml performs before it). The diff touches no TypeScript source, so the reading cannot move; CI runs it with the closure built.The retired gate's self-test retires with the gate — nothing invokes it any more (grep-verified: the only remaining mentions of the retired names are the audit header's history section and the registry's tombstone + ledger row).
Live sweep exercised end-to-end in this container: a 24h window enumerated 11 governed merges from local git with 11 attribution lookups, and correctly classified the container's missing token as attribution-incomplete (exit 2) rather than a clean sweep.
.claude/+.github/+ scripts + instruction files only — publishes nothing;skip-changesetlabel applied on this PR (read-modify-write, read back beside the bot labels).Generated by Claude Code