Skip to content

ci(ci-status): skip sibling re-runs from a draft full run - #69

Merged
kyle-sexton merged 1 commit into
mainfrom
ci/draft-rerun-siblings
Oct 5, 2026
Merged

kyle-sexton merged 1 commit into
mainfrom
ci/draft-rerun-siblings

Conversation

@kyle-sexton

Copy link
Copy Markdown
Member

No related issue: follow-up to #68 for the draft gap found in dotfiles#1031 and provisioning#704.

Summary

rerun-contract-only-siblings is now ${{ github.event.pull_request.draft && 'false' || 'true' }}, so a draft full run re-runs nothing.

Fix

One line in .github/workflows/pr-require-checks.yml. The repo has no refuse-a-draft step, so the live-state draft check from the addendum does not apply. No test asserts the input; none exists for this workflow.

Verification

actionlint .github/workflows/pr-require-checks.yml: clean. CI on this PR.

Related

#68, melodic-software/dotfiles#1031, melodic-software/provisioning#704.

🤖 Generated with Claude Code

rerun-contract-only-siblings is now false while the pull request is a draft
and true otherwise, matching dotfiles#1031 and provisioning#704. The repo has
no refuse-a-draft step, so the live-state draft check does not apply.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@kyle-sexton
kyle-sexton marked this pull request as ready for review October 5, 2026 01:36
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 5, 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-05T01:40:22.441718Z ac50554 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 5, 2026 •

Copy link
Copy Markdown

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


Security review (/review:security-review)

  • Gather context (PR diff, changed file)
  • Review change against security criteria
  • Report findings

Scope: one line in .github/workflows/pr-require-checks.yml (ac50554):

-          rerun-contract-only-siblings: 'true'
+          rerun-contract-only-siblings: ${{ github.event.pull_request.draft && 'false' || 'true' }}

Findings: none.

Reasoning:

  • The expression is a with: input to a pinned, first-party composite action (aggregate-results@d49c4915...), not a run: shell block, so there's no expression-injection/command-injection path — github.event.pull_request.draft is a boolean the attacker doesn't control the shape of, and it never reaches a shell.
  • No permissions: widening, no trigger changes (pull_request_target, workflow_run), no new secrets exposure — those are zizmor's advisory lane anyway, out of scope here per this lane's rules.
  • This narrows an existing re-run trigger (skip rerunning contract-only siblings while the PR is a draft) rather than broadening any capability; actions: write scope is unchanged and pre-existing.
  • Not an instruction-surface deletion: this is a CI re-run condition, not a standing guardrail/rule file (CLAUDE.md, AGENTS.md, a skill/agent body, a hook allowlist). docs/conventions/instruction-exception-register/README.md is not present in this repo, so that registry wasn't consulted, but it doesn't apply to this diff regardless — no standing instruction is being removed, narrowed, or softened.

No security issues found.

@claude

claude Bot commented Oct 5, 2026 •

Copy link
Copy Markdown

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


Claude's code review

Scope. Single-line change: rerun-contract-only-siblings goes from the literal 'true' to ${{ github.event.pull_request.draft && 'false' || 'true' }}, so a full run triggered from a draft PR no longer re-runs red contract-only sibling runs on the same head SHA. The 'false'/'true' string-ternary pattern is safe here (both branches are non-empty strings, so the &&/|| emulation doesn't misfire), and the expression degrades correctly to 'true' on push/merge_group events where github.event.pull_request doesn't exist.

Finding posted inline (.github/workflows/pr-require-checks.yml:147): this file documents the "why" behind every other non-trivial conditional at length — the if: predicates, the concurrency group, even timeout-minutes: 3 — but the new draft ternary has no comment at all, even sitting right under a comment block that explains the adjacent yield-to-full-run mechanism. The rationale exists in the commit message (draft gap from dotfiles#1031 / provisioning#704, no refuse-a-draft step in this repo) but per this file's own convention that belongs inline, not only in history.

Not re-raised as findings (noted for transparency, not blocking):

  • No test asserts this input — acknowledged by the author; this workflow has no existing test harness for its own inputs, so this isn't a new gap introduced by this PR.
  • actionlint ... clean and "CI on this PR" in the Verification section are author-claimed; actionlint isn't installed in this environment so I could not independently confirm it.

@kyle-sexton
kyle-sexton merged commit c35d421 into main Oct 5, 2026
9 checks passed
@kyle-sexton
kyle-sexton deleted the ci/draft-rerun-siblings branch October 5, 2026 01:37
@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown

claude-security-review has reviewed this pull request through ac50554; 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: ac505544b7

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

# the `success` and replace their red check runs.
yield-to-full-run: 'true'
rerun-contract-only-siblings: 'true'
rerun-contract-only-siblings: ${{ github.event.pull_request.draft && 'false' || 'true' }}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Trigger a healing run when the draft becomes ready

When a draft full run overlaps a labeled, unlabeled, or contract-only edited run, the sibling deliberately fails while yielding to the full run, but this new value prevents that full run from rerunning and healing it. Because the workflow's event types omit ready_for_review, marking the PR ready starts no replacement run, leaving the required ci-status red and blocking the merge until an unrelated push/edit/label event or manual rerun occurs; either handle ready_for_review or otherwise heal these siblings once the draft is ready.

AGENTS.md reference: AGENTS.md:L5-L5

Useful? React with 👍 / 👎.

# the `success` and replace their red check runs.
yield-to-full-run: 'true'
rerun-contract-only-siblings: 'true'
rerun-contract-only-siblings: ${{ github.event.pull_request.draft && 'false' || 'true' }}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Maintainability: this file documents the rationale for every other non-obvious conditional inline — the if: predicates, the concurrency group, yield-to-full-run, even timeout-minutes: 3 get multi-line "why" comments (e.g. lines 15-34, 41-72, 140-146 directly above this line). The new github.event.pull_request.draft && 'false' || 'true' ternary is the one conditional in the file with no explanation at all, even though the comment block right above it (140-146) walks through the adjacent yield-to-full-run mechanism in detail and says nothing about draft state.

The rationale does exist — it's in the commit message ("rerun-contract-only-siblings is now false while the pull request is a draft... matching dotfiles#1031 and provisioning#704. The repo has no refuse-a-draft step, so the live-state draft check does not apply.") — but per this file's own established convention, that belongs in an inline comment, not only in history a future reader of the YAML won't see.

Fix this →

@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown

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

kyle-sexton added a commit that referenced this pull request Oct 5, 2026
… again (#70)

## Summary

Reverts the draft-conditional `rerun-contract-only-siblings` value from
#69 back to `'true'`.

This repo's `pull_request` trigger omits `ready_for_review`
(pr-require-checks.yml line 35), and no lane is gated on draft. A draft
full run therefore runs every lane, and its sibling re-runs are safe.
Skipping them on a draft can leave a yielded red contract-only
`ci-status` stuck after the PR is marked ready, because nothing re-runs
it. The same reasoning closed cursor-plugins#85 (Codex review P2).

## Related

Follow-up to #69.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
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