fix(merge): non-fast-forward safety + restore the five sweep merges main lost #5464
ccantynzAI Reviewcommented 24d ago
AI Triage
(no summary)
Priority: medium Risk area: mixed
Suggested labels: (no label suggestions) Suggested reviewers: (no reviewer suggestions)
Suggestions only — nothing has been applied. The PR author stays in control.
gluecron[bot]🤖 botAI Reviewcommented 24d ago
AI review unavailable
The platform's AI balance is exhausted, so AI generation is temporarily unavailable. Nothing was lost. You can queue this as a repair for the internal agent from the repository's Health page, or try again once the balance is restored. The PR is otherwise unchanged.
Cross-repo impact
See what breaks downstream if this PR merges.
⮌ Merged
This pull request was merged into main.
c comment · e edit title · m merge · a approve · r request changes · ? shortcuts
INCIDENT: the merge endpoint's bare
update-ref base headonly is a merge when base is an ancestor of head. Six parallel sweep branches shared an older base; each sequential "merge" replaced main with that branch's tip, silently discarding the previous ones. Five merged PRs (#5457–#5462) vanished from main while reading "merged". Caught by post-deploy browser verification; all commits survived on their branches.This PR (a true descendant of current main — safe under old and new logic):
update-refsites (shared executorpr-merge.ts+merge-queue.tsx) now rungit merge-base --is-ancestorfirst; non-fast-forward heads route throughmergeWithAutoResolvefor a genuine merge commit (clean merges need no AI; conflicted-and-behind fails honestly).tsc clean; all four new sweep test files green (48/48).
🤖 Generated with Claude Code