Skip to content

Land clean pull requests through auto-merge - #665

Merged
polewskm merged 35 commits into
mainfrom
claude/gracious-heisenberg-vgvu4w
Nov 30, 2026
Merged

polewskm merged 35 commits into
mainfrom
claude/gracious-heisenberg-vgvu4w

Conversation

@polewskm

@polewskm polewskm commented Nov 30, 2026 •

Copy link
Copy Markdown
Collaborator

Under the Landing section's merge: auto, /run-issues, /run-issues-all-in and /run-feedback, in Claude Code, Copilot Chat and Copilot CLI, land a clean pull request themselves. They resolve only the threads ADR-0066 lets them resolve and run the default branch's copy of .template/Test-MergeGate.ps1 -Landing, never the pull request's. Only when it exits 0 do they pick the first merge method the repository allows (merge commit, rebase, squash, as ADR-0065 decision 3 orders them), mark the pull request ready and turn on auto-merge, and they make it a draft again when auto-merge doesn't go on. They never press merge, count only their own Autopilot: comments and only the named review bot's approval, and treat a failed read as not clean.
Two new partials, _land-auto.md (Land the Pull Request) and _stop-the-line.md (Stop the Line), carry the stage. After the merge, the commands wait for every Actions run on the merge commit. A run that still fails after one re-run stops every landing in the repository. They then open a pull request that reverts the merge, told apart from the merge itself as a merge commit, a rebase or a squash. That revert lists the protected paths it changes. A tagged release isn't reverted. Their fix budget for a broken default branch is zero, so they never fix forward (ADR-0067 decision 4).
Every new rule is guarded by merge=auto, so under merge: person, the default, every rule reads as before; merge=invalid and merge=unenforceable land as person does. The one unguarded sentence documents the merge key in /ship-plan item 2 and says /ship-plan lands the same under each value. tests/Test-Template.ps1 pins the guards and the old prohibitions word for word.
/ship-plan, workflow/templates/README.md, the template's AGENTS.md.jinja, CLAUDE.md and Copilot instructions, and USAGE.md document the merge key. A new project gets - merge: person, and the changelog's v0.152.0 section describes the release.

Protected paths changed:
.claude/commands/run-feedback.md
.claude/commands/run-issues-all-in.md
.claude/commands/run-issues.md
.claude/commands/ship-plan.md
.github/prompts/run-feedback.prompt.md
.github/prompts/run-issues-all-in.prompt.md
.github/prompts/run-issues.prompt.md
.github/prompts/ship-plan.prompt.md
.github/skills/run-feedback/SKILL.md
.github/skills/run-issues-all-in/SKILL.md
.github/skills/run-issues/SKILL.md
.github/skills/ship-plan/SKILL.md
template/.claude/commands/run-feedback.md
template/.claude/commands/run-issues-all-in.md
template/.claude/commands/run-issues.md
template/.claude/commands/ship-plan.md
template/.github/instructions/project-template.instructions.md.jinja
template/.github/prompts/run-feedback.prompt.md
template/.github/prompts/run-issues-all-in.prompt.md
template/.github/prompts/run-issues.prompt.md
template/.github/prompts/ship-plan.prompt.md
template/.github/skills/run-feedback/SKILL.md
template/.github/skills/run-issues-all-in/SKILL.md
template/.github/skills/run-issues/SKILL.md
template/.github/skills/ship-plan/SKILL.md
template/CLAUDE.md

Release: v0.152.0
Closes #655


Generated by Claude Code

@ncode-review ncode-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 NCode Review at 1d72d86: 14 new findings on the changed lines.

Not on a changed line:

  • 🟡 F9 Nit: Stop the Line leaves cancelled and action_required runs undecided .github/prompts/run-feedback.prompt.md:58. Item 1 counts failure, timed_out and startup_failure as failed, and item 3 counts only success, skipped and neutral as passed, so a completed cancelled or action_required run is neither. Fix: Treat any completed conclusion other than success, skipped or neutral as not passed, and say whether it stops the line or only gets a notice.

Comment thread template/.claude/commands/run-issues.md Resolved
Comment thread .github/skills/run-issues/SKILL.md Resolved
Comment thread workflow/templates/_stop-the-line.md Resolved
Comment thread .github/skills/run-issues/SKILL.md Resolved
Comment thread .github/prompts/run-feedback.prompt.md Resolved
Comment thread .github/prompts/run-feedback.prompt.md Resolved
Comment thread workflow/templates/_stop-the-line.md Resolved
Comment thread workflow/templates/_land-auto.md Resolved
Comment thread workflow/templates/_land-auto.md Resolved
Comment thread .github/skills/run-issues/SKILL.md Resolved
@ncode-review

ncode-review Bot commented Nov 30, 2026 •

Copy link
Copy Markdown

Superseded by the review at a7b4a60.

Copy link
Copy Markdown
Collaborator Author

/review


Generated by Claude Code

@ncode-review ncode-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 NCode Review at a7b4a60: 4 new findings on the changed lines.
1 more was already posted on this pull request.

Not on a changed line:

  • 🟡 F5 Nit: ship-plan's new merge sentence isn't guarded by merge=auto template/.github/prompts/ship-plan.prompt.md:2. The new sentence in ship-plan item 2 ('this command lands the same under each value: it never marks a pull request ready, turns on auto-merge or merges') has no merge=auto guard, although the description says every new sentence does. Is it meant as the key's documentation? Fix: Either guard the sentence, or reword the description to say the merge key's documentation in ship-plan is unguarded on purpose.

Comment thread .claude/commands/run-issues.md Resolved
Comment thread .github/skills/run-issues/SKILL.md Resolved
@ncode-review

ncode-review Bot commented Nov 30, 2026 •

Copy link
Copy Markdown

Superseded by the review at 77ebfd1.

Copy link
Copy Markdown
Collaborator Author

/review


Generated by Claude Code

@ncode-review ncode-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 NCode Review at 77ebfd1: 4 new findings on the changed lines.
4 more were already posted on this pull request.

Comment thread .github/prompts/run-issues.prompt.md Resolved
Comment thread template/.claude/commands/run-issues.md Resolved

Copy link
Copy Markdown
Collaborator Author

/review


Generated by Claude Code

@ncode-review ncode-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 NCode Review at 9765f70: 3 new findings on the changed lines.
3 more were already posted on this pull request.

Comment thread .claude/commands/run-issues.md Resolved
Comment thread template/.claude/commands/run-issues.md Resolved
Comment thread .github/prompts/run-issues.prompt.md Resolved

@ncode-review-approver ncode-review-approver Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved at 9765f70: no blocker or should-fix finding remains.

@ncode-review

ncode-review Bot commented Nov 30, 2026 •

Copy link
Copy Markdown

Superseded by the review at 32c7e51.

Copy link
Copy Markdown
Collaborator Author

/review


Generated by Claude Code

@ncode-review ncode-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 NCode Review at 32c7e51: 3 new findings on the changed lines.
4 more were already posted on this pull request.

Comment thread .claude/commands/run-issues-all-in.md Resolved
Comment thread .claude/commands/run-issues.md Resolved
Comment thread template/.claude/commands/run-issues.md Resolved

@ncode-review-approver ncode-review-approver Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved at 32c7e51: no blocker or should-fix finding remains.

@ncode-review

ncode-review Bot commented Nov 30, 2026 •

Copy link
Copy Markdown

Superseded by the review at e54bd62.

Copy link
Copy Markdown
Collaborator Author

/review


Generated by Claude Code

@ncode-review ncode-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 NCode Review at e54bd62: 4 new findings on the changed lines.
2 more were already posted on this pull request.

Comment thread .github/prompts/run-feedback.prompt.md Resolved
Comment thread .github/skills/run-issues/SKILL.md Resolved

@ncode-review-approver ncode-review-approver Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved at e54bd62: no blocker or should-fix finding remains.

@ncode-review

ncode-review Bot commented Nov 30, 2026 •

Copy link
Copy Markdown

Superseded by the review at 92afe1a.

Copy link
Copy Markdown
Collaborator Author

/review


Generated by Claude Code

@ncode-review ncode-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 NCode Review at 92afe1a: 1 new finding on the changed lines.
3 more were already posted on this pull request.

@ncode-review-approver ncode-review-approver Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved at 92afe1a: no blocker or should-fix finding remains.

@ncode-review

ncode-review Bot commented Nov 30, 2026 •

Copy link
Copy Markdown

🤖 Review complete

Verdict: 💬 Comment — This PR adds a merge: auto landing stage (_land-auto.md) and a stop-the-line stage (_stop-the-line.md) to /run-issues, /run-issues-all-in and /run-feedback in every runtime. Every new rule is guarded by merge=auto, so behaviour under merge: person is unchanged, and tests/Test-Template.ps1 pins the guards word for word. The design holds together: it runs the default branch's copy of the landing check, never presses merge, treats a failed read as not clean, and always reverts instead of fixing forward. The main remaining risk is that no person checks for protected paths before a pull request auto-merges. After this summary was written, verification couldn't settle one finding, now a question one severity lower.

Approval: Approved — no blocker or should-fix finding remains.

6 reviewers run — 1 finding, 3 already raised (run details)

Reviewer Model Findings Top
synthesis opus-5-5 1 🟡
conventions sonnet-5-5 0 🟢
correctness sonnet-5-5 1 🟡
hygiene haiku-5-5 0 🟢
intent haiku-5-5 0 🟢
rule-check sonnet-5-5 2 🟡
security sonnet-5-5 1 🟠

Skipped: api-compat, architecture, completeness, data-model, infrastructure, performance, tests

Findings
  • 🟡 F2 template/.github/prompts/run-issues.prompt.md:167: Is counting a cancelled run as a real failure intended?
Already raised (3)

Threads on this pull request already raise these, so they aren't posted again or counted in the findings; a dismissed one isn't counted in the verdict either.

  • 🟡 F1 template/.claude/commands/run-issues.md:149: Is a protected-path check of the whole pull request needed before auto-merge? (already raised as F4)
  • 🟡 F3 tests/Test-Template.ps1:1949: Code comment cites the issue this pull request closes (already raised as F8, dismissed)
  • 🟡 F4 workflow/templates/_land-auto.md:10: Commit-id pattern doesn't say it matches case-sensitively (already raised as F4, dismissed)

Trial: findings are posted as review threads and in the check run. $3.57 on Amazon Bedrock, 182s, at 92afe1a. (how to interact)

📋 Outcomes

Merged at 92afe1a: 30 fixed, 21 dismissed, 0 acknowledged, 0 ignored.

Finding Reviewer Severity Outcome
F1 at 1d72d86 security 🟠 Should fix ✅ fixed
F2 at 1d72d86 correctness 🟠 Should fix ✅ fixed
F3 at 1d72d86 intent 🟠 Should fix ✅ fixed
F4 at 1d72d86 security 🟡 Nit ✅ fixed
F5 at 1d72d86 security 🟡 Nit ✅ fixed
F6 at 1d72d86 security 🟡 Nit 👎 dismissed
F7 at 1d72d86 correctness 🟡 Nit ✅ fixed
F8 at 1d72d86 rule-check 🟡 Nit ✅ fixed
F10 at 1d72d86 rule-check 🟡 Nit ✅ fixed
F11 at 1d72d86 rule-check 🟡 Nit ✅ fixed
F12 at 1d72d86 rule-check 🟡 Nit ✅ fixed
F13 at 1d72d86 rule-check 🟡 Nit ✅ fixed
F14 at 1d72d86 intent 🟡 Nit 👎 dismissed
F15 at 1d72d86 hygiene 🟡 Nit ✅ fixed
F1 at a7b4a60 correctness 🟠 Should fix ✅ fixed
F2 at a7b4a60 security 🟡 Nit ✅ fixed
F4 at a7b4a60 security 🟡 Nit ✅ fixed
F6 at a7b4a60 rule-check 🟡 Nit ✅ fixed
F1 at 77ebfd1 rule-check 🟠 Should fix ✅ fixed
F5 at 77ebfd1 rule-check 🟡 Nit ✅ fixed
F7 at 77ebfd1 rule-check 🟡 Nit 👎 dismissed
F8 at 77ebfd1 security 🟡 Nit 👎 dismissed
F2 at 4b07d69 security 🟡 Nit 👎 dismissed
F4 at 4b07d69 rule-check 🟡 Nit ✅ fixed
F5 at 4b07d69 hygiene 🟡 Nit ✅ fixed
F6 at 4b07d69 hygiene 🟡 Nit ✅ fixed
F8 at 4b07d69 rule-check 🟡 Nit 👎 dismissed
F2 at 55a6508 security 🟡 Nit 👎 dismissed
F4 at 55a6508 intent 🟡 Nit 👎 dismissed
F1 at 2641c62 correctness 🟡 Nit 👎 dismissed
F5 at 2641c62 hygiene 🟡 Nit ✅ fixed
F1 at 36ce3b4 security 🟡 Nit 👎 dismissed
F2 at 36ce3b4 rule-check 🟡 Nit 👎 dismissed
F4 at 36ce3b4 intent 🟡 Nit 👎 dismissed
F3 at 36ce3b4 rule-check 🟡 Nit ✅ fixed
F4 at 36ce3b4 rule-check 🟡 Nit ✅ fixed
F1 at f4c27ae correctness 🟡 Nit 👎 dismissed
F4 at f4c27ae rule-check 🟡 Nit ✅ fixed
F6 at f4c27ae rule-check 🟡 Nit 👎 dismissed
F7 at f4c27ae intent 🟡 Nit 👎 dismissed
F1 at 9765f70 security 🟡 Nit 👎 dismissed
F3 at 9765f70 correctness 🟡 Nit 👎 dismissed
F4 at 9765f70 rule-check 🟡 Nit ✅ fixed
F1 at 32c7e51 correctness 🟡 Nit 👎 dismissed
F3 at 32c7e51 rule-check 🟡 Nit ✅ fixed
F5 at 32c7e51 rule-check 🟡 Nit 👎 dismissed
F1 at e54bd62 correctness 🟡 Nit ✅ fixed
F2 at e54bd62 rule-check 🟡 Nit ✅ fixed
F3 at e54bd62 rule-check 🟡 Nit ✅ fixed
F4 at e54bd62 rule-check 🟡 Nit 👎 dismissed
F2 at 92afe1a correctness 🟡 Nit 👎 dismissed

Copy link
Copy Markdown
Collaborator Author

Autopilot: this pull request is ready to merge as far as this run can tell, at 92afe1a0.

Why:

  • Since the recommendation at 36ce3b41, the run fixed each NCode Review finding that held, in plan steps 29 to 35: the Rules' merge=auto exception now names re-drafting and turning auto-merge off, the all-in report and ending are guarded, a reply's commit id is checked before it reaches git, the merge-method order cites ADR-0065 decision 3, and Stop the Line handles an empty, unreadable or still-running run list and a failed git worktree add. It declined the rest with the reason on each thread.
  • NCode Review's approver approved 92afe1a0: no blocker or should-fix finding remains. Its one new finding repeats the cancelled-run point and is answered.
  • tests/Test-Template.ps1 passes. CI on 92afe1a0 has no failed check; "Test the adoption checklist script" and "Test the repository baseline script" were still running when this was written.

Left as a follow-up, which /ship-plan files once this merges: "Stop the line under merge: person too".

Protected paths this pull request changes are the same 26 listed in the description and in #665 (comment).

Unresolved thread, answered, for you to resolve before you merge:

Merge it with a merge commit or by rebasing, not by squashing, then run /finish-plan issue-655.


Generated by Claude Code

@polewskm
polewskm enabled auto-merge November 30, 2026 05:55
@polewskm
polewskm merged commit 1003512 into main Nov 30, 2026
81 checks passed
@polewskm
polewskm deleted the claude/gracious-heisenberg-vgvu4w branch November 30, 2026 06:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Land a clean pull request through auto-merge under merge: auto

1 participant