fix(dev-loop): merging a finished PR is pre-authorized -- merge, close, clean up, then report - #507
Merged
Merged
Conversation
…e, clean up, then report Sessions stopped at the end of a finished dev loop to ask permission to merge. State the durable authorization in CLAUDE.md, the copilot-instructions Merge Step and dev-loop Phase 8; separate the mandatory independent review from the permission that is not; replace the bare "never merge while CI is red" with a hosted-CI-unavailable clause (developer-confirmed switch to local CI, real counts in the PR; a hosted run that failed stays a hard stop); and list the only cases that still stop and ask. Refs #499 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Fda3nBeB9rJBPdJSmD7sRN
…very CI checkpoint Address the independent review of the merge pre-authorization: - The developer's confirmation of a switch to local CI must be verifiable by any session or reviewer: a linked, timestamped developer comment cited in the PR, or the repository's own committed instructions or config. A personal or session-local memory note does not count. - Name the owner's second condition: while on local CI, hosted CI is rechecked daily and the repository switches back as soon as it works. That is the shared local-CI runner's job, not implemented by hand. - The dev-loop-phase-gate Phase 7 checklist's "CI workflows are green" now carries the hosted-CI-unavailable exception and points at CLAUDE.md. - dev-loop Phase 7 step 4 cross-references the Phase 8 exception for the case where no runs appear. - Every bare "CI green" precondition in dev-loop and copilot-instructions now says "(or the hosted-CI-unavailable exception below applies)". Refs #499 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Fda3nBeB9rJBPdJSmD7sRN
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 free
to 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.
Closes #499
What this changes
Merging a finished dev-loop PR is pre-authorized: when the exit criteria hold, merge, close the issue, clean up the worktree without asking, then report in the Task Complete Summary Format. The report replaces the permission prompt.
main.hold; the reviewer's model is not recorded; the PR belongs to another session or author; the change is outside the approved design.Stated canonically in
CLAUDE.md(new section Merging a Finished PR Is Pre-Authorized), restated in the Merge Step of.github/copilot-instructions.mdand Phase 8 of.github/agents/dev-loop.agent.md, and thedev-loop-phase-gatechecklist's CI item carries the same exception. Every "CI is red" / "CI green" occurrence in the tree is now qualified.Verification (local -- hosted CI is billing-blocked)
Invoke-Pester -Path .\.github(CI-equivalent, 71 files)merge-preauthorized.Tests.ps1(new)Independent review
Reviewer: Claude Sonnet 5 (author: Opus). Round 1: CHANGES REQUESTED -- 1 Critical (the "recorded" location was not verifiable), 2 Important (the owner's daily-recheck condition missing; the phase-gate checklist unqualified), 2 Minor (cross-references). All five accepted and fixed in
e3c3627. Round 2: ACCEPT, no new findings.Held for the owner
This PR changes the agents' own authorization rules, and an automated safety check flagged it as instruction-shaped. It is not being merged under the rule it introduces -- it waits for the owner's explicit go-ahead.
🤖 Generated with Claude Code
https://claude.ai/code/session_01Fda3nBeB9rJBPdJSmD7sRN