Install the fleet no-op merge guard shim — a PR must not merge green and change nothing - #218
Merged
Merged
Conversation
connector#1008 merged as 610c6860 and `git show 610c6860 --numstat` returns zero files: a duplicate PR from an already-merged branch, whose squash landed an empty commit while its title and ticket history claimed the work was done. Green checks, a closed ticket, and no change. GitHub's Files-changed tab could not have shown it — that is the THREE-dot diff, and block#1008's was not empty. What was empty was the MERGE RESULT. This shim forwards this repo's pull_request events to toon-meta's empty-pr-guard.yml, which diffs `refs/pull/N/merge` against its base parent — the diff the squash commit would actually carry. Verbatim copy of the canonical shim at toon-meta/scripts/factory/empty-pr-guard-shim.yml. No `secrets: inherit` (the guard makes no API call and no write) and no branch filter (a human's duplicate PR is exactly what merged empty). Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
ALLiDoizCode
enabled auto-merge (squash)
August 16, 2026 20:37
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.
Installs this repo's copy of the fleet no-op merge guard, landed in toon-meta#405.
What it guards.
connector#1008merged as610c6860andgit show 610c6860 --numstatreturns zero files — a second PR opened from the same branch 17 minutes afterconnector#1000had already merged that branch's content, so its squash landed an empty commit while its title and ticket history claimed the work was done. Green checks, a closed ticket, a merge commit, and no change. Nothing noticed; a human caught it by diffing the file.Nothing could have caught it from the PR page either: GitHub's Files-changed tab is the three-dot diff and block#1008's was not empty. What was empty was the merge result.
What this file does. Forwards this repo's
pull_requestevents totoon-protocol/toon-meta/.github/workflows/empty-pr-guard.yml@main, which checks outrefs/pull/N/merge— the merge of the head branch into the base tip, which apull_requestrun already checks out — and diffs it against its base parent. That diff is what the squash commit would carry. Empty diff, empty merge, red check with a message naming the shape and the recovery.Verbatim copy of the canonical shim at
toon-meta/scripts/factory/empty-pr-guard-shim.yml, diffed against it before this PR was opened.No credential, no branch filter. No
secrets: inherit— the guard makes no API call and no write, so handing itFACTORY_OPS_TOKENwould widen a monitored credential for nothing. Nosandcastle//agent/filter — a human's duplicate PR is exactly what merged empty.How it blocks.
checksVerdictcounts any non-plumbing red check asfailing, so from this merge on, an empty PR here is ineligible for the fleet auto-merge pass — no branch-protection change needed. Making it hard-block a human merge is a separate, per-repo choice: add the job to this repo's aggregate required check.Behaviour on a legitimate no-op: there isn't one. Checked across all eleven factory repos before building this — nothing here merges an empty PR on purpose, and no release, tag or deploy flow rides an empty commit (moving tags move by
docker buildx imagetools create). A conflicted PR, which has no merge ref, warns and passes.Part of the guard's fleet fan-out. Full rationale:
toon-meta/FACTORY.md→ "Empty-PR guard (no-op merges)".🤖 Generated with Claude Code