Skip to content

Auto-merge: say so when the merge will trigger nothing - #2

Merged
jcasimir merged 1 commit into
mainfrom
automerge-deploy-trigger
Sep 11, 2026
Merged

jcasimir merged 1 commit into
mainfrom
automerge-deploy-trigger

Conversation

@jcasimir

Copy link
Copy Markdown
Member

Native auto-merge performs the merge as whoever enabled it. With no AUTOMERGE_PAT that is github-actions[bot], and GitHub deliberately does not trigger workflows from a GITHUB_TOKEN push. So the merge commit lands on the default branch having started nothing — no deploy, and no CI on the default branch either.

This is invisible by construction: CI passes (it triggers on pull_request), the PR merges, every dashboard is green, and production silently stops changing. Frontier lost 18 merges and about four and a half hours to exactly this on 2026-09-10, and the workflow file reported state: active throughout.

The shim now still queues the merge — it is gated on CI either way, and blocking it would cost more than it saves — and then fails the job when no PAT is set, naming the fix. A red check is the only thing standing between this failure mode and nobody noticing.

The real fix is an org-level AUTOMERGE_PAT, which covers every repo at once and makes this check go quiet everywhere. Deliberately not made conditional on whether this repo has a deploy: one invariant beats a per-repo exception list.

🤖 Generated with Claude Code

https://claude.ai/code/session_016Rn19FnLSwT7aje6gTam39

A PR merged by native auto-merge is merged as whoever enabled it. With no
AUTOMERGE_PAT that is github-actions[bot], and GitHub does not trigger
workflows from a GITHUB_TOKEN push. The merge lands on the default branch
having started nothing at all — no deploy, and no CI on the default branch
either.

It fails silently in the worst way: CI is green, the PR merges, every
dashboard agrees, and production just stops changing. Frontier lost 18 merges
and four and a half hours to this on 2026-09-10 before anyone noticed.

The merge is still queued and still gated on CI — blocking it would cost more
than it saves. But the job now fails afterwards, loudly, naming the fix, so
the gap cannot pass for success.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016Rn19FnLSwT7aje6gTam39
@jcasimir
jcasimir merged commit a8a96cb into main Sep 11, 2026
3 checks passed
@jcasimir
jcasimir deleted the automerge-deploy-trigger branch September 11, 2026 02:18
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.

1 participant