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
{{ message }}
Repository navigation
auto-rebase: default eligibility to all; remove dead review-ready code; lock merge-method invariant #927
Part of #926 (AC1 + AC3 + reusable-side cleanup for AC5).
Flip auto-rebase-reusable.yml's eligibility input default from review-ready to all.
Remove the now-dead review-ready eligibility mode and ready_label input plumbing from lib/eligibility.sh and the reusable, since nothing needs to opt around an approval gate that no longer exists.
Add/keep a regression test asserting update-branch is always called with update_method=merge, never rebase — this must not regress.
See #926's "Decisions (2026-08-02)" section for rationale (accepting CI cost — measured ~50s/re-test, <0.5% of serial-merge capacity per docs/initiatives/auto-rebase-vs-merge-queue.md §5 in petry-projects/.github-private).
Issue:#927 — auto-rebase: default eligibility to all; remove dead review-ready code; lock merge-method invariant
Scope
Flip the reusable auto-rebase eligibility default from review-ready to all, delete the now-dead review-ready mode and ready_label plumbing from lib/eligibility.sh and the reusable, and add a regression test pinning update_method=merge (never rebase).
lib/eligibility.sh — dropped review-ready mode + auto_rebase_has_ready_label + auto_rebase_has_current_approval; auto_rebase_pr_eligible MODE now handles only all (0) / unknown (2)
auto-rebase-reusable.yml — default flipped to eligibility: all; removed ready_label input, READY_LABEL env, the HAS_LABEL/IS_APPROVED computation, and the review-ready-only <!-- auto-rebase-stuck --> escalation block (unreachable under all); updated header/input comments. Conflict/blocked sentinel handling untouched.
Contract docs updated to match: .github/scripts/auto-rebase/README.md, standards/ci-standards.md, and the copy-paste stub standards/workflows/auto-rebase.yml
Regression test test/workflows/auto-rebase/merge-method.bats pins update_method=merge, asserts the rebase method never appears
eligibility.bats trimmed to the surviving contract + added guards that the removed mode/helpers are gone
Test Results
1..13
ok 1 post_comment_best_effort: comment-cap failure is non-fatal (returns 0)
ok 2 post_comment_best_effort: failure logs a continue warning naming the PR
ok 3 post_comment_best_effort: success returns 0, posts the comment, no warning
ok 4 post_comment_best_effort: a capped PR does not abort a bash -e loop over multiple PRs
ok 5 pr_eligible all: every behind PR is eligible
ok 6 pr_eligible: unknown mode errors out (exit 2)
ok 7 pr_eligible: empty mode errors out (exit 2)
ok 8 pr_eligible: the removed review-ready mode is rejected as unknown (exit 2)
ok 9 auto_rebase_has_current_approval is no longer defined
ok 10 auto_rebase_has_ready_label is no longer defined
ok 11 merge-method: reusable workflow file exists
ok 12 merge-method: update-branch is called with update_method=merge
ok 13 merge-method: update-branch is never called with the rebase method
Also passing: shellcheck -x on both libs, .dev-lead/scripts/dev-lead-lint.sh (all checks passed), yamllint (repo CI config, max: 200), and actionlint 1.7.7 (repo CI invocation) on all three workflow files.
The eligibility input and the pure-predicate architecture are kept as the documented extension seam for a future "front-of-queue N" mode, per the reusable's own design note — only the review-ready implementation was removed.
Left untouched deliberately: docs/initiatives/pull-request-limits-adr.md still says the eligibility lever is "(already review-ready)". That is a point-in-time ADR record outside this issue's scope; rewriting historical decision records seemed inappropriate. Flag if you'd prefer it updated.
Activity
don-petry commentedon Aug 3, 2026
Dev-Lead Implementation Plan
Issue: #927 — auto-rebase: default eligibility to all; remove dead review-ready code; lock merge-method invariant
Scope
Flip the reusable auto-rebase
eligibilitydefault fromreview-readytoall, delete the now-deadreview-readymode andready_labelplumbing fromlib/eligibility.shand the reusable, and add a regression test pinningupdate_method=merge(neverrebase).Implementation Checklist
.github/scripts/auto-rebase/lib/eligibility.sh— dropreview-readycase,auto_rebase_has_ready_label,auto_rebase_has_current_approval; keepauto_rebase_pr_eligible(all+ unknown-mode only).github/workflows/auto-rebase-reusable.yml— defaulteligibility: all; removeready_labelinput,READY_LABELenv, theHAS_LABEL/IS_APPROVEDcomputation, and the review-ready-only stuck-escalation block; update header comments.github/scripts/auto-rebase/README.md— update eligibility contract tablestandards/ci-standards.md— update eligibility table + default to matchTests to Write
test/workflows/auto-rebase/merge-method.bats(new) — assert the reusable callsupdate-branchwithupdate_method=mergeand neverrebasetest/workflows/auto-rebase/eligibility.bats— remove tests for deleted functions/mode; keepall+ unknown-mode cases (single-arg signature)Test Command
bats test/workflows/auto-rebase/(plusshellcheck -x .github/scripts/auto-rebase/lib/*.shandbash .dev-lead/scripts/dev-lead-lint.sh)don-petry commentedon Aug 3, 2026
Dev-Lead: Implementation Complete
Plan Execution
lib/eligibility.sh— droppedreview-readymode +auto_rebase_has_ready_label+auto_rebase_has_current_approval;auto_rebase_pr_eligible MODEnow handles onlyall(0) / unknown (2)auto-rebase-reusable.yml— default flipped toeligibility: all; removedready_labelinput,READY_LABELenv, theHAS_LABEL/IS_APPROVEDcomputation, and the review-ready-only<!-- auto-rebase-stuck -->escalation block (unreachable underall); updated header/input comments. Conflict/blocked sentinel handling untouched..github/scripts/auto-rebase/README.md,standards/ci-standards.md, and the copy-paste stubstandards/workflows/auto-rebase.ymltest/workflows/auto-rebase/merge-method.batspinsupdate_method=merge, asserts therebasemethod never appearseligibility.batstrimmed to the surviving contract + added guards that the removed mode/helpers are goneTest Results
Also passing:
shellcheck -xon both libs,.dev-lead/scripts/dev-lead-lint.sh(all checks passed), yamllint (repo CI config,max: 200), and actionlint 1.7.7 (repo CI invocation) on all three workflow files.Files Changed
.github/workflows/auto-rebase-reusable.yml: defaultall; removedready_label/approval plumbing + stuck-escalation block.github/scripts/auto-rebase/lib/eligibility.sh: reduced to theallmode dispatch.github/scripts/auto-rebase/README.md,standards/ci-standards.md,standards/workflows/auto-rebase.yml: contract/docs syncedtest/workflows/auto-rebase/eligibility.bats: pruned dead tests, added removal guardstest/workflows/auto-rebase/merge-method.bats(new): merge-method invariant regression guardNotes
eligibilityinput and the pure-predicate architecture are kept as the documented extension seam for a future "front-of-queue N" mode, per the reusable's own design note — only the review-ready implementation was removed.<!-- auto-rebase-stuck -->escalation (issue auto-rebase deadlock: 'review-ready' gate skips unapproved PRs but the auto-rebase:ready label is never applied (#465 gap) #711) was removed because it fired only on the skip path, which is unreachable once every behind PR is eligible; it was dead review-ready code.docs/initiatives/pull-request-limits-adr.mdstill says the eligibility lever is "(alreadyreview-ready)". That is a point-in-time ADR record outside this issue's scope; rewriting historical decision records seemed inappropriate. Flag if you'd prefer it updated.feat: implement issue #927 — auto-rebase: default eligibility to all;…