Skip to content

ci: clear the merge-ready conflict status on a clean re-check - #10135

Merged
EffortlessSteven merged 7 commits into
mainfrom
claude/project-thread-erluuj
Oct 25, 2026
Merged

EffortlessSteven merged 7 commits into
mainfrom
claude/project-thread-erluuj

Conversation

@EffortlessSteven

Copy link
Copy Markdown
Member

Requested by Steven · project thread

Summary

  • Follow-up to ci: report merge-ready requests on conflicting PRs #9847. The failing merge-ready conflict status stayed red on a head until its next push, even after the base moved and the conflict disappeared. Now a re-applied merge-ready label that finds a computed, non-dirty state looks up the latest merge-ready conflict status on the head and, only if it is failure, posts success. It never touches other contexts and posts nothing when no earlier failure exists.
  • Adds a test case to xtask/tests/merge_ready_conflict_notice.rs (clears its own failure; leaves an already-cleared status and a different context alone). Raises the workflow's run-block budget from 40 to 50 lines, updates docs/CI.md, and adds a changelog.d fragment.

Source-of-truth Links

Governing issue or accepted claim: #9842 (follow-up to merged #9847)
Acceptance delta (one sentence): a conflict status posted by the notice workflow clears on a re-check once the conflict is gone.

Proof

7 test cases pass locally against real jq and a fake gh; check-workflows, check-process-policy, check-policy-all and check-changelog-fragments pass. The live behavior needs a labeled PR that conflicts and is then fixed on the same head, which I will run after merge.


Generated by Claude Code

…nflict (#9842)

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01M1HLQzDSYhzcGBd9baf3RV
@gemini-code-assist

Copy link
Copy Markdown

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@coderabbitai

coderabbitai Bot commented Oct 24, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

  • Ask an admin to enable usage-based reviews

Open in CodeRabbit

Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing.

Next included review available in 51 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available. Your 162 included PR review attempts over the past 7 days set your current allowance at 1 review per hour.

Learn how review limits work.

Review configuration:

Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: ASSERTIVE
  • Plan: Essentials
  • Run ID: fe4c1c68-3159-4136-97bc-b71c5488acb0
Commits

Reviewing files that changed from the base of the PR and between 6212bda and 269d77a.

Files selected for processing: 5
  • .github/workflows/merge-ready-conflict-notice.yml
  • changelog.d/9842-conflict-status-clears.md
  • docs/CI.md
  • policy/workflow_allowlist.txt
  • xtask/tests/merge_ready_conflict_notice.rs
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Comment @coderabbitai help to get the list of available commands.

Copy link
Copy Markdown
Member Author

Review of record, head 54fd420

Angles: security and correctness/tests, by an independent read-only reviewer on 88f748a, then my repair.

  • Security: no blocking findings. Trigger is the label (triage or write access only); the status context is a literal, so it cannot clear or spoof Ripr Rust Small Result; head and base are verified live before any write; no checkout; job-level pull-requests: write and statuses: write only.
  • Correctness: no blocking findings. The list endpoint returns newest first, so [0] is the latest; // "none" is null-safe; the null-mergeability and stale head/base exits run before the clear; blocked, behind and unstable correctly count as no conflict.
  • Two lows, both fixed here: "clears only its own failure" was not enforced (the filter checked the context, not the creator), so the select now also requires creator.login == "github-actions[bot]"; and the success wording over-claimed, so it now reads "No conflict with ".
  • Tests: 8 cases pass against real jq and a fake gh. New cases: a failure posted by another creator is not cleared; a moved head never clears a status on the requested head. Existing cases confirm that only the latest status for the context counts and that another context is never touched.
  • Gates: check-workflows, check-process-policy, check-policy-all pass locally.

Disclosed limit: a conflict that resolves stays red until merge-ready is re-applied; sweeping labeled PRs is tracked in #10136. Live check of the clearing path follows after merge.


Generated by Claude Code

@EffortlessSteven
EffortlessSteven marked this pull request as ready for review October 24, 2026 23:09
@gemini-code-assist

Copy link
Copy Markdown

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01M1HLQzDSYhzcGBd9baf3RV

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Decision

  • Needs verification checks before upstream.

Verification questions

  • Confirm the lookup selects the first matching context/creator entry and treats that entry as authoritative, but the diff does not establish that GitHub returns combined statuses newest-first.
  • Confirm the history query requests only 100 statuses without pagination, so a prior workflow-owned failure outside that page can be missed.

Evidence gaps

  • The prior review thread reported 8 passing tests and repository policy checks, but the current sensor record marks ripr failed and cargo-test receipt-absent; no fresh executable proof is available in this lane.
  • Model proof intent was rejected by deterministic validation.
  • zizmor hardening evidence is unavailable and ripr failed, so workflow security and full Rust proof are not independently established.

…43, python 30, perl 23)

main's blessed rows moved past the committed ceilings, so the ceiling test is red on main itself; same change as #10140 with values re-measured on the current head.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01M1HLQzDSYhzcGBd9baf3RV

Copy link
Copy Markdown
Member Author

The required check was red from main, not from this diff: committed_ceilings_equal_the_blessed_missed_credit fails on main itself (rust ceiling 135 against 143 blessed). The fix-of-record #10140 carries stale values (rust 134), so I ported re-measured ones (rust 143, python 30, perl 23) in the latest commit. They no-op once main carries them. Re-applying merge-ready.


Generated by Claude Code

Copy link
Copy Markdown
Member Author

On the advisory review's two questions: GitHub's "list commit statuses" endpoint returns newest first, and the sweep PR's tests (#10142) pin that order with a newer-success-over-older-failure case. On pagination, one head would need more than 100 statuses before a bot failure fell off the first page, and the cost of a miss is one missing success flip on a non-required status. I am not adding pagination for that. The executable proof is the required check running on the current head.


Generated by Claude Code

The ceiling bump is waiting on Steven and does not belong in this diff.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01M1HLQzDSYhzcGBd9baf3RV

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Decision

  • Needs verification checks before upstream.

Verification questions

  • Confirm the fixture does not prove the production API's newest-first ordering because it supplies statuses as an ordered array and the test harness preserves that order.
  • Confirm the fixture supplies statuses in an assumed newest-first order, so it does not distinguish selecting the first list entry from selecting the latest matching failure across older entries.
  • Confirm the workflow treats the first matching status as authoritative, but requests only the newest 100 statuses without pagination.

Refuted

  • The implementation needs a broader helper or abstraction to avoid duplication.; refuted because: Rejected: the change adds a small test harness parameter and preserves the existing execution path; extracting production API helpers would add scope without removing meaningful duplication.

Parked follow-ups

  • The workflow's prior-status lookup is limited to 100 combined statuses, so a workflow-owned failure older than the first page is not found.

Evidence gaps

  • Fresh executable Rust proof is not yet available in the packet despite focused behavioral tests being added.
  • Model proof intent was rejected by deterministic validation.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Decision

  • Needs verification checks before upstream.

Verification questions

  • Confirm the test fake does not prove the production API's newest-first ordering; it merely preserves fixture order and takes the first matching item.
  • Confirm the fixture preserves caller-supplied status order, so it does not independently prove that the production API returns newest-first.
  • Confirm the test harness models the API response order directly, so it does not independently prove that GitHub's first matching combined-status entry is authoritative across all matching entries.
  • Confirm focused tests cover creator filtering, context filtering, already-cleared statuses, and moved-head protection.

Refuted

  • The focused fixture may prove GitHub's newest-first API ordering.; refuted because: It does not: the fake API returns a preselected array verbatim. The seeded thread provides a source assertion, so this remains an open oracle gap rather than a proven production bug.
  • The implementation needs a broader helper or abstraction to avoid duplication.; refuted because: Rejected: the change adds a small test-harness parameter and preserves the existing execution path; extracting production API helpers would increase scope without removing meaningful duplication.

Parked follow-ups

  • A workflow-owned failure older than the first 100 combined statuses may be missed; this remains a bounded parked follow-up rather than a red/green defect.
  • The status lookup uses only the first 100 combined statuses, so an older workflow-owned failure beyond that page is not found.

Evidence gaps

  • Fresh executable Rust proof is unavailable in the packet: ripr failed and the cargo-test receipt is still pending.
  • Model proof intent was rejected by deterministic validation.

Copy link
Copy Markdown
Member Author

Review of record, head 269d77a

Angles: security, correctness and tests, read against the diff on this head.

  • Security: the write is a commit status with the fixed merge-ready conflict context only, posted only when the latest status from the actions bot with that context is failure and the live read shows a computed, non-dirty state. It never touches other contexts (so it cannot affect Ripr Rust Small Result), checks nothing out, and takes PR-derived values only through env. A moved head or base posts nothing.
  • Correctness: the 8-case suite covers dirty, null-then-dirty retry, never-computed, clean/blocked/behind/unstable, moved head or retargeted base, an existing marker, clearing only its own failure (foreign creator and other context left alone), and a moved head never clearing. Status order (newest first) is GitHub's documented order for that endpoint, and ci: watchdog reports and clears merge-ready conflicts #10142's tests pin the sweep's use of it.
  • Findings: the advisory bot's pagination question (more than 100 statuses on one head) is parked, since the cost of a miss is one missing success flip on a non-required status. No blocking findings.
  • Delta since the last review: merges of main only; the corpus-ceiling commit I carried briefly was reverted and is out of this diff.

CI: Ripr Rust Small Result, Rust gates and Admit PR Candidate pass on this exact head; no unresolved threads.


Generated by Claude Code

@EffortlessSteven
EffortlessSteven merged commit b38dd8d into main Oct 25, 2026
44 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants