fix(ci): resolve PR diff bases live instead of the stale payload SHA (#10785) - #10964
Conversation
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
Thanks for tracking down the stale event-payload base issue here. I reviewed the workflow diffs and this looks like the right direction: the changed jobs already use I’m not seeing a blocker in the patch, and the current CI is green. Because this touches CI/workflow behavior and is tied to an earlier failure class, I’m leaving it for human maintainer review rather than formal automated approval. by AI on behalf of David — if you need David’s attention urgently, please @Git-on-my-level and escalate with |
|
Independently verified the final head (af679b9 → 3b2b687):
@cubic-dev-ai's review was 5/5 / no issues; your note on not needing another cubic pass is correct. @Git-on-my-level confirmed no blocker from automation and CI is green. This is a correct, minimal stale-diff-base fix (FC-stale-event-payload-diff-base). Still needs your human maintainer sign-off on the workflow behavior change (needs-maintainer-review / workflow-review). |
3b2b687 to
4618709
Compare
…asedHardware#10785) Three workflows still diffed against github.event.pull_request.base.sha, which is only as fresh as the last event that populated it: a queued or re-triggered run can diff against a base the target branch has since moved past, silently widening or narrowing diff-scoped check selection (FC-stale-event-payload-diff-base, registered after BasedHardware#10784 / PR BasedHardware#10758). Switch all three to the canonical prevention: resolve origin/<base-ref> live against the fetch-depth:0 checkout in the same job, matching the detect-changes action used by repo-checks.yml. - backend-unit-tests.yml: changed-files base - desktop-swift-ci.yml: DIFF_BASE for path detection - backend-hermetic-e2e.yml: PR_BASE_REF for hermetic scope The fourth call site named in the issue (desktop-backend-image-checks.yml) was removed with the retired Node agent cloud, so only three remain. Failure-Class: FC-stale-event-payload-diff-base Co-authored-by: CommandCodeBot <noreply@commandcode.ai>
The scope step now diffs against origin/<base-ref> (live, matching detect-changes) instead of the event-payload base.sha which can be stale for a queued run (FC-stale-event-payload-diff-base, BasedHardware#10785). Update the wiring contract test to assert the new PR_BASE_REF pattern and that the stale base.sha reference is gone. Co-authored-by: CommandCodeBot <noreply@commandcode.ai>
4618709 to
b3bfe0b
Compare
|
Rebased the actual PR branch onto latest |
|
@Git-on-my-level need human response — this is still blocked on code-owner review for CI/workflow behavior. Your earlier AI pass was a positive signal (no blocker): jobs already use What’s left is the formal human / |
|
@Git-on-my-level quick follow-up: PR #10964 remains CI-green at b3bfe0b with Cubic 5/5 and your earlier positive signal. The only remaining merge blocker is the required workflow code-owner approval; no code or CI changes are pending. |
Keep the live-diff-base workflow fix current for CO re-check.
|
@Git-on-my-level need human response — workflow code-owner APPROVE still the only merge blocker on #10964. Refreshed tip
Your earlier AI pass found no blocker; Cubic 5/5. Please human / workflow-review APPROVE (or explicit hold) when you can. |
Pick up desktop glass tripwire updates so Desktop Swift CI is not failing on stale AgentPill/SettingsGlassChrome contracts.
|
@Git-on-my-level need human response — Desktop Swift red on Merged current
Please human / workflow-review APPROVE (or explicit hold) when CI re-greens. |
|
@Git-on-my-level need human response — #10964 still blocked only on CI/workflow code-owner APPROVE. Author-clear on tip
Please human / |
|
Thanks for keeping this focused. I re-reviewed the current head and I don’t see a code blocker in this CI/workflow diff. Specific notes:
Validation I checked locally/static:
Because this touches CI/workflow behavior, I’m leaving it for human workflow-owner/code-owner sign-off rather than formal automation approval. — Reviewed by Omi maintainer automation (glm-5.2) by AI on behalf of David — if you need David’s attention urgently, please @Git-on-my-level and escalate with |
|
@Git-on-my-level need human response — formal workflow/code-owner APPROVE is still the only merge blocker on #10964. Author-clear on tip
Please human / |
|
@Git-on-my-level @undivisible review ping — this one is ready and has been waiting 1 day. MERGEABLE, no failing checks on the current head. It resolves PR diff bases live instead of the stale payload SHA (#10785). Blocked only on workflow CODEOWNER approval — One thing worth flagging so it isn't read as red: the Still current and still author-side clear. Verified against |
Fixes #10785
What changed and why
Three workflows still diffed against
github.event.pull_request.base.sha, which is only as fresh as the last event that populated it. A queued or metadata-re-triggered run can diff against a base the target branch has since moved past — silently widening or narrowing diff-scoped check selection. This is exactly theFC-stale-event-payload-diff-basefailure class registered after #10784 (which fixedrepo-checks.ymlafter PR #10758 hit a false invariant-citation failure).All three now resolve the base live against the
fetch-depth: 0checkout in the same job, matching thedetect-changesaction's canonical pattern (origin/<base-ref>):.github/workflows/backend-unit-tests.yml—changed-filesbase for the authoritative backend unit contract..github/workflows/desktop-swift-ci.yml—DIFF_BASEfor Swift path detection..github/workflows/backend-hermetic-e2e.yml—PR_BASE_REFfor hermetic backend scope.The fourth call site named in the issue (
desktop-backend-image-checks.yml) was removed with the retired Node agent cloud, so only three remain.Product invariants affected
None (CI workflow changes only).
How it was verified
actionlint .github/workflows/{backend-unit-tests,desktop-swift-ci,backend-hermetic-e2e}.yml— clean.grep -rn "event.pull_request.base.sha" .github/workflows/— no remaining usages.python3 .github/scripts/check_deployment_secret_boundary.py --base origin/main— passed.python3 .github/scripts/check_runner_cost_policy.py— passed.scripts/failure-class prepare— declaration validated.Tests
No test change — this is CI workflow diff-base resolution. The regression guard is the failure-class contract (
FC-stale-event-payload-diff-base) plus thedetect-changesaction's existing behavior, which these now match.Failure class (fixes)
Failure-Class: FC-stale-event-payload-diff-base
Scoped cleanups
None.