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
Phase 6 (#144) ships with Option A — human-in-loop: STAGE 5 opens a promote PR; a human reviews and merges. This issue tracks the Option C — auto-merge with self-validation end state.
When this lands, weekly digest-bump PRs will auto-merge once claude-pr-review/quality-gate posts success on the rebuilt overlay's self-review. The dogfood becomes the gate: a healthy overlay's review persona green-lights its own promotion; a regressed overlay's review fails, blocking the conveyor and triggering operator response.
Motivation
Inquisitor Pass 1 on the Phase 6 plan (2026-05-05) identified that the "fully automated promotion" framing in the master plan didn't reconcile with the bot-authored promote PR being subject to required claude-pr-review/quality-gate. Three viable resolutions were considered:
B. App as ruleset bypass actor — bypass the gate entirely for App-authored PRs. Rejected: expands App blast radius; if PEM leaks, gate-bypassed PRs can be opened.
C. Auto-merge with self-validation — chosen for follow-up (this issue). True automation + gated.
Acceptance Criteria
STAGE 5 promote PR enables auto-merge — either via peter-evans/create-pull-request's auto-merge input or a follow-up step that calls gh pr merge --auto --squash
Auto-merge waits for claude-pr-review/quality-gate to post success before merging (default GitHub auto-merge behavior with required checks)
Rollback workflow (runtime-rollback.yml) is hardened with the pre-PR validation from Charge 5 of Inquisitor Pass 1 — this is a hard prerequisite because a stuck conveyor must be unstuck-able by rollback
STAGE 5 promote PR includes a "kill switch" comment / label that, when applied by an operator, disables auto-merge for that specific PR (operator override path)
Documented runbook for "promote PR's quality-gate failed; how do I diagnose and recover" — at minimum a section in CLAUDE.md "CI Runtime"
At least 4 successful auto-merge cycles observed before this issue closes (one weekly cadence per overlay change-class — base, review, fix, explain — to exercise the conveyor end-to-end)
Technical Notes
Auto-merge mechanics on bot PRs.peter-evans/create-pull-request documents an auto-merge input that calls the GitHub auto-merge API. Verify this works for App-authored PRs (some auto-merge paths require human confirmation; the API call from the action should bypass that).
Failure mode: bad overlay freezes the conveyor. A regression in any overlay's review persona will flip claude-pr-review/quality-gate to failure on the promote PR. All subsequent promotes pile up. Recovery: dispatch runtime-rollback.yml to revert to the last-known-good pubsha. The rollback PR is also bot-authored, so it MUST also be auto-mergeable — but rollback PRs may need a different gate (you don't want quality-gate to evaluate the broken overlay's own review). Spec amendment may be needed to give rollback its own bypass path.
Quiet-window guard. Consider adding a "quiet-window" check that suppresses auto-merge during ongoing CI activity (e.g., open PRs against main with pending CI). Reduces blast radius if a regression slips in.
Summary
Phase 6 (#144) ships with Option A — human-in-loop: STAGE 5 opens a promote PR; a human reviews and merges. This issue tracks the Option C — auto-merge with self-validation end state.
When this lands, weekly digest-bump PRs will auto-merge once
claude-pr-review/quality-gatepostssuccesson the rebuilt overlay's self-review. The dogfood becomes the gate: a healthy overlay's review persona green-lights its own promotion; a regressed overlay's review fails, blocking the conveyor and triggering operator response.Motivation
Inquisitor Pass 1 on the Phase 6 plan (2026-05-05) identified that the "fully automated promotion" framing in the master plan didn't reconcile with the bot-authored promote PR being subject to required
claude-pr-review/quality-gate. Three viable resolutions were considered:Acceptance Criteria
peter-evans/create-pull-request'sauto-mergeinput or a follow-up step that callsgh pr merge --auto --squashclaude-pr-review/quality-gateto postsuccessbefore merging (default GitHub auto-merge behavior with required checks)runtime-rollback.yml) is hardened with the pre-PR validation from Charge 5 of Inquisitor Pass 1 — this is a hard prerequisite because a stuck conveyor must be unstuck-able by rollbackCLAUDE.md"CI Runtime"Technical Notes
peter-evans/create-pull-requestdocuments anauto-mergeinput that calls the GitHub auto-merge API. Verify this works for App-authored PRs (some auto-merge paths require human confirmation; the API call from the action should bypass that).claude-pr-review/quality-gatetofailureon the promote PR. All subsequent promotes pile up. Recovery: dispatchruntime-rollback.ymlto revert to the last-known-goodpubsha. The rollback PR is also bot-authored, so it MUST also be auto-mergeable — but rollback PRs may need a different gate (you don't want quality-gate to evaluate the broken overlay's own review). Spec amendment may be needed to give rollback its own bypass path.inventory-match.sh+ overlay-smoke validation. That hardening is a hard prerequisite for this issue.Out of Scope
References
docs/superpowers/plans/phase-6-promotion.mdplan refresh log) — Charges 2 (this trade-off) and 5 (rollback hardening prerequisite)agent-memory/general-purpose/feedback_gh_actions_not_addable_ruleset_bypass.md— explains why Option B was rejected🤖 Generated by Claude Code on behalf of @cbeaulieu-gt