Skip to content

ci(ci-status): yield a contract-only run to the full run instead of waiting - #757

Merged
kyle-sexton merged 3 commits into
mainfrom
ci/ci-status-yield
Oct 10, 2026
Merged

kyle-sexton merged 3 commits into
mainfrom
ci/ci-status-yield

Conversation

@kyle-sexton

@kyle-sexton kyle-sexton commented Oct 10, 2026 •

Copy link
Copy Markdown
Member

Related

Fix

A contract-only ci-status run (edited, labeled, unlabeled) used to wait up to 840 s for an in-flight full run on the same head SHA. It now adopts the ci-workflows v0.39.3 aggregate-results yield:

  • yield-to-full-run: 'true': a contract-only run fails at once with "superseded by full run" while a full run is in flight; that run's newer ci-status decides the gate.
  • rerun-contract-only-siblings: 'true': the full run re-runs those red contract-only runs once it records success. Not draft-gated, because this workflow has no draft gate and no "Refuse a draft" step.
  • carry-forward-wait-seconds: '0' and timeout-minutes: 3, sized as the reference PRs did, since neither path waits.
  • actions: write on ci-status (covers the run listing and the re-run). No record-pending, per the fleet-wide least-privilege ruling.

Every ci-workflows reference still resolves to ab83b01 (v0.39.3), which the runner policy approves. Only standards' own CI caller changes; the file is not in the sync manifest.

🤖 Generated with Claude Code

https://claude.ai/code/session_01TRhsMPSTMFo99ik7gkdgQt

…aiting

Adopt the ci-workflows v0.39.3 aggregate-results yield: a contract-only
ci-status fails at once while a full run is in flight on the head SHA,
and the full run re-runs those red siblings once it records success.
carry-forward-wait-seconds drops to 0, timeout-minutes to 3, and
ci-status gains actions: write for the run listing and re-run. No
record-pending, and the re-run is not draft-gated because this workflow
is not.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01TRhsMPSTMFo99ik7gkdgQt
@kyle-sexton
kyle-sexton marked this pull request as ready for review October 10, 2026 17:50
@claude

claude Bot commented Oct 10, 2026 •

Copy link
Copy Markdown

Claude finished @kyle-sexton's task in 1m 21s —— View job


Security review complete

  • Gather context (PR diff, changed workflow file)
  • Check for instruction-surface deletions (AGENTS.md / rules files) — none; this diff touches only .github/workflows/pr-require-checks.yml
  • Review pr-require-checks.yml diff for security-relevant changes
  • Fan out hunters / verifiers — not needed; single-file, mechanical config diff reviewed directly
  • Post findings

No security issues found.

Scope reviewed: the ci-status job in .github/workflows/pr-require-checks.yml, which is the only changed file.

Notes on what I checked and why it doesn't rise to a finding here:

  • Permission widening (actions: read → actions: write): this is the kind of change zizmor's advisory lane already flags, so per this lane's scope I only report it if it needs logic/trust-boundary reasoning beyond "permissions widened." I traced the added scope to its actual use — yield-to-full-run (list runs) and rerun-contract-only-siblings (re-run) inside the pinned, SHA-locked aggregate-results@ab83b01 composite action from melodic-software/ci-workflows. None of the step inputs feeding that action (treat-skipped-as, yield-to-full-run, rerun-contract-only-siblings, carry-forward-wait-seconds, results) are attacker-influenced — results is built from needs.*.result, which is only ever success/failure/skipped/cancelled. There's no attacker-controlled string (PR title, branch name, labels) reaching a run: block or API call under this elevated token.
    • For fork PRs, GITHUB_TOKEN is forced read-only by GitHub regardless of the requested permissions: block (the existing in-file comment on the concurrency block already documents this), so the write grant can't be exercised by an untrusted fork contributor. A same-repo (non-fork) branch already requires repo write access to open, so this isn't a privilege escalation path.
  • Removed wait / lowered timeout (carry-forward-wait-seconds: 840 → 0, timeout-minutes: 15 → 3): this changes race-condition handling (which run's ci-status becomes authoritative) but doesn't weaken the contract gate itself — a superseded contract-only run now fails fast instead of blocking, and the full run's own ci-status still decides the gate. No path found where this causes an unreviewed/failing PR to merge as if it passed.
  • Instruction-surface lens: this diff doesn't touch AGENTS.md, rules files, or any hook allow/deny list — it's CI-workflow config, not a standing instruction being deleted or softened, so that lens doesn't apply here.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 10, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-10T17:52:52.242910Z 5bc93de Draft marked ready
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@claude

claude Bot commented Oct 10, 2026 •

Copy link
Copy Markdown

Claude finished @kyle-sexton's task in 5m 5s —— View job


Review: ci(ci-status): yield a contract-only run to the full run instead of waiting (#757)

  • Gather context (PR diff, workflow file, sibling-repo rationale, runner-policy approval record)
  • Review the single changed file against correctness/maintainability criteria
  • Investigate one candidate finding (timeout headroom) with an independent adversarial verifier
  • Post findings

Scope: .github/workflows/pr-require-checks.yml only (+20/-13), the lone changed file. Security-relevant aspects (the actions: write permission grant) are left to the dedicated security lane (pr-review-security.yml) per this repo's lane split.

What I checked:

  • The ci-status job's new yield-to-full-run / rerun-contract-only-siblings / carry-forward-wait-seconds: '0' inputs against the updated comments explaining them — internally consistent with each other and with the top-of-file concurrency: block rationale they reference.
  • actions: write replacing actions: read — needed because rerun-contract-only-siblings re-runs sibling workflow runs via the Actions API, which read can't do; write is a superset so "write covers the read" holds.
  • melodic-software/ci-workflows@ab83b01 (v0.39.3) is the version components/runner-policy/README.md records as policy-approved, and that doc's history shows pr-require-checks/aggregate-results last changed at v0.38.2 (docs(review): drop the retired claude-review lane names #696/chore(runner-policy): approve ci-workflows v0.36.0 contracts #697) and has been byte-identical since — so the yield-to-full-run/rerun-contract-only-siblings inputs this PR newly passes were already present at the pinned SHA, not a version mismatch.
  • I considered whether dropping timeout-minutes from 15 to 3 leaves enough headroom now that the full run's ci-status step also lists and re-runs red contract-only siblings (a cost that didn't exist before, and the file's own concurrency comment acknowledges sibling bursts under repeated label flips). I ran this past an independent verifier agent rather than report it on instinct: the rerun calls are fire-and-forget (the job doesn't block on the reran workflows finishing), realistic sibling counts per SHA are small per that same comment, and no concrete repro pushes this past 180s — so it didn't clear the high-signal bar and I'm not reporting it.

No findings meet the bar for this lane (a careful senior reviewer would block/flag). The change is a config-and-comment update to an already-vendored, policy-approved external action, and the new comments accurately describe the new behavior.

Branch ·

@github-actions

github-actions Bot commented Oct 10, 2026 •

Copy link
Copy Markdown

claude-security-review has reviewed this pull request through 621555a; a later push is reviewed from there.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5bc93dee35

ℹ️ 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".

Comment thread .github/workflows/pr-require-checks.yml Resolved
@github-actions

Copy link
Copy Markdown

PR body contract — issue linkage

This PR body does not yet satisfy the issue-linkage contract:

  • Missing a "## Summary" section. Describe what this PR changes and why, in a sentence or two.
  • Missing a "## Verification" section. Record concrete evidence the change works (commands, gates, output).
  • Missing a native closing keyword (Closes/Fixes/Resolves #N). If this PR references an issue it must not close, put "Refs: #N" (or "Relates to: #N") on its own line. If it relates to no GitHub issue at all, state "No linked issue" (or "No related issue:") in the body instead.

Edit the body and this comment updates itself on the next run.

@github-actions

github-actions Bot commented Oct 10, 2026 •

Copy link
Copy Markdown

claude-review has reviewed this pull request through 621555a; a later push is reviewed from there.

@kyle-sexton
kyle-sexton merged commit 94f621e into main Oct 10, 2026
55 of 56 checks passed
@kyle-sexton
kyle-sexton deleted the ci/ci-status-yield branch October 10, 2026 18:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant