You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(gate): lift the bot's own manual-review hold, and stop drafts wedging the merge train (#9942)
Two independent reasons an autonomous queue stalls with no human in it, both
found on live PRs.
1) The manual-review label was a ONE-WAY LATCH.
The sibling-label cleanup deliberately refuses to touch it, because the same
label string is also a maintainer's manual freeze and the planner had no way to
tell them apart -- and silently undoing a human's freeze is far worse than
leaving a stale hold. That caution was right; the missing piece was provenance.
Seen on #9935: the label went on when a finding fired against a stale head, a
rebase removed the cause, a fresh escalated review returned ZERO findings, and
the PR was mergeable, green and clean -- and still would not merge:
agent.action.merge | denied | manual-review label "manual-review" is present
on the live PR -- merge not executed
It took a human removing the label by hand, in the mode that is supposed to
have no human in it.
The planner now records the head SHA and reason when IT applies the label, and
may lift it once manualHoldReason is null (no reason wants a hold this pass, so
a label applied for reason A can never be lifted by reason B clearing). A label
with NO provenance -- a human's, or one predating this -- is never touched.
That asymmetry is the whole safety property.
2) A draft sibling wedged the merge train.
The train already evicts conflicted and manual-review-held siblings on the
principle that waiting for a PR which is not trying to reach merge buys nothing
the 24h cap does not already bound far worse. A DRAFT is the strongest form of
that signal: GitHub itself refuses to merge one, so it is not one merge away
from landing, it is one author action away from being eligible at all.
The production shape: a maintainer PR with red CI cannot be auto-closed
(maintainers are exempt on purpose, so they can iterate), so it stays open and
overlapping for as long as the fix takes -- holding every newer overlapping PR
behind it, green and approved, for up to the full 24 hours. Marking it draft is
the author saying "skip me", and the train now understands that.
Eviction removes ONE PR from the queue; it does not disable the gate. A real
older sibling behind the draft still holds the line.
0 commit comments