Repository navigation
fix(source-control): hold a CLEAN babysit head that is behind a loose base - #6165
Conversation
… base Under loose required status checks GitHub reports a behind head CLEAN, and the gate compared the head against its base only on BLOCKED, so it could squash-merge a behind head. The merge gate now compares an otherwise-ready head against the live base on a base with neither strict checks nor a merge queue, and holds it while behind or unreadable. The snapshot reports the same head behind so the guarded refresh can clear the hold; a queue base is left as before. Closes #5955 Co-authored-by: ksextonmelodic <ksextonmelodic@gmail.com>
…-base-e44b Co-authored-by: ksextonmelodic <ksextonmelodic@gmail.com>
…ds and docs Count a strict required_status_checks rule only when it lists a check, since GitHub's strict setting takes no effect without one. Leave the merge-queue flag unknown on a failed rules read so the snapshot reports a CLEAN head not behind for that cycle instead of refreshing a possible queue base. Skip a behind head as a review-request candidate. State that the gate checks freshness at gate and arm time only, reads rulesets but not classic branch protection, and holds on a persistently failing compare until a human acts; correct the cost wording and a broken reflow. Co-authored-by: ksextonmelodic <ksextonmelodic@gmail.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Claude finished @kyle-sexton's task in 6m 32s —— View job CI code review —
|
|
Claude finished @kyle-sexton's task in 1m 55s —— View job Security review (
|
|
claude-security-review has reviewed this pull request through 977a7ba; a later push is reviewed from there. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 977a7ba11d
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
claude-review has reviewed this pull request through 977a7ba; a later push is reviewed from there. |
…tream sections Co-authored-by: ksextonmelodic <ksextonmelodic@gmail.com>
|
Babysit triage of the two bot review summaries on head
Both reviews ran before |
Summary
Under loose required status checks GitHub reports a head that is behind its base as
CLEAN. The babysit merge gate made no base compare, and the queue snapshot compared only aBLOCKEDhead, so the gate could squash-merge a behind head and drop base commits, even thoughfreshness.mdcallsbehinda hard stop.Fix
baseFreshness. This happens at gate time, including when the gate arms--auto; an already-armed auto-merge is not re-checked if the base moves later, a race that predates this PR.required_status_checksrule that lists at least one check, since GitHub's strict setting "will not take effect unless at least one status check is enabled" (rules API). Classic branch protection is not read; such a base pays one extra compare, never a wrong merge.BLOCKED,CLEANorHAS_HOOKSPR on every cycle, and reports a behindCLEAN/HAS_HOOKShead asbranch_freshness.state == "behind"so the guarded refresh clears the hold.behind, matching the live re-check inrequest_review.py.mainhas a queue, so the gate's behaviour here does not change.reference/freshness.md(with a dated source record) andreference/safety.mddescribe the hold, its timing and its cost.source-controlgoes to 0.79.8 with a CHANGELOG entry.Verification
CLEAN/HAS_HOOKShead behind a loose base is not held, auto-merge arms over a behind head, the snapshot does not report a behindCLEANhead, a strict rule with no checks skips the compare, a failed rules read marks the head behind, and the review-request candidate picks a behind head.BLOCKEDkeeps its fallback; a PR already held makes no compare.engine.test.sh: 11 PASS, 0 FAIL. The other affected suites (babysit-wrapper-help,nesting-invariant-ssot,check-contract-clause-coverage) pass.run-ruff.sh check, typos, markdownlint-cli2, gitleaks and all four changelog-parity checks pass.mainis unaffected.Related
Closes #5955
Builds on #5935 and #6148 (merge-queue handling).