Skip to content

fix(eval): a held or otherwise blocked PR does not take bonsai-merge-first - #1158

Merged
skyrocket2026 merged 1 commit into
mainfrom
fix/bonsai-held-pr-not-merge-first
Sep 24, 2026
Merged

skyrocket2026 merged 1 commit into
mainfrom
fix/bonsai-held-pr-not-merge-first

Conversation

@skyrocket2026

Copy link
Copy Markdown
Member

At the end of each round, reconcile_bonsai_merge_labels excluded only needs-rebase PRs when choosing the bonsai-merge-first winner. So a PR under hold, or carrying any other AUTOMERGE_BLOCK label, could still win. Its merge was then refused, and the next-best PR was pushed to needs-rebase for a merge that never happened.

Where it came up: today #1154 was put on hold for review while holding the round's best score (XL, +35.4%). It would have taken merge-first every round for as long as the hold lasted, blocking every other Bonsai PR.

Fix:

  • Blocked PRs are left out of the ranking.
  • A stale bonsai-merge-first on a blocked PR is removed.

Tests: ReconcileTests. A held XL PR neither wins nor demotes the next-best PR; without a hold, the best still wins. 42 tests pass.

…first

reconcile_bonsai_merge_labels skipped only needs-rebase PRs when picking the round's winner. A PR
under hold -- or any other AUTOMERGE_BLOCK label -- could still win merge-first, have its merge
refused, and push the next-best PR to needs-rebase for a merge that never happened. On 2026-09-24
#1154 was held for review with the round's best score (XL, +35.4%), which would have done that to
every other Bonsai PR for as long as the hold lasted.

Blocked PRs are now left out of the ranking, and a stale merge-first on one is removed.
@skyrocket2026 skyrocket2026 added the hold Maintainer override: never auto-merge this PR label Sep 24, 2026
@skyrocket2026
skyrocket2026 merged commit 7586d04 into main Sep 24, 2026
5 checks passed
@skyrocket2026
skyrocket2026 deleted the fix/bonsai-held-pr-not-merge-first branch September 24, 2026 21:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

hold Maintainer override: never auto-merge this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant