Skip to content

ci: verify merge parents after a pull request retarget - #1948

Merged
mldangelo-oai merged 1 commit into
mainfrom
mdangelo/codex/ci-verify-retarget-merge
Oct 25, 2026
Merged

mldangelo-oai merged 1 commit into
mainfrom
mdangelo/codex/ci-verify-retarget-merge

Conversation

@mldangelo-oai

Copy link
Copy Markdown
Collaborator

Summary

Three pull request retargets started CI on a test merge whose first parent was still the previous base. In two of those cases, the checkout omitted changes from the requested target, including the shard runner in one case and the CI classifier in the other. Shard runner checkout · Classifier checkout

Changes

On a pull request retarget, compare the checked-out merge commit's ordered parents with the base and head SHAs in GitHub's event payload before selecting jobs. Report the requested base ref and both SHA pairs. A mismatch fails classification and propagates through the existing required gate.

Testing

  • All 10 Node CI selection and result-gate tests passed.
  • All 18 workflow-quality tests passed with 196 assertions. The Git fixture checks matching parents, a stale base, and a stale head. Each mismatch exited before emitting selections.
  • A hosted draft changed target in both directions without changing its source head. In each direction, the event carried the new base and Actions fetched the previous merge. The comparison rejected both before source jobs started. The final patch generalizes the diagnostic wording. Forward retarget · Return to main
  • Replaying the hosted event's actual SHAs against both Git merge objects at depth two rejected the stale commit with zero outputs and selected the full matrices on the correct commit.
  • The focused release dependency test passed with 69 assertions. Actionlint with ShellCheck, Prettier, and the whitespace check passed.

Risk and rollout

A retarget with a stale checkout stops in the Linux classifier before the expensive jobs start. A new pull request event after GitHub refreshes the merge ref can test the updated tree. GitHub uses the original commit when rerunning an existing attempt. GitHub rerun documentation

Public disclosure review

  • No customer, partner, prospect, or user identities, data, or identifying details are included.
  • No credentials, personal data, private source, scan findings, or nonpublic links or tickets are included.
  • I reviewed the branch name, title, description, commits, changes, comments, logs, screenshots, attachments, and links for public disclosure.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 24, 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-24T17:06:13.043394Z c4e2c8a PR opened
🔒 Security Review ✅ Completed 2026-10-24T17:06:43.755049Z c4e2c8a PR opened
ℹ️ 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.

@alandelong-oai alandelong-oai left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks — no blocking findings in this owner-level merge-safety pass. Retargeted runs now stop before emitting selections when the checked-out merge parents differ from the event, and the existing aggregate gate propagates that failure. The change stays confined to the classifier and its fixture.

Validation: all 10 Node selection/gate tests and 19 focused Bun workflow/release tests passed (265 Bun assertions), along with SDK/MCP typechecking, changed-file formatting and whitespace checks. Reviewed both hosted retarget failures and their actual parent pairs. Full platform CI was not rerun locally.

@mldangelo-oai
mldangelo-oai merged commit 16f3660 into main Oct 25, 2026
76 checks passed
@mldangelo-oai
mldangelo-oai deleted the mdangelo/codex/ci-verify-retarget-merge branch October 25, 2026 00:52
@github-actions github-actions Bot mentioned this pull request Oct 25, 2026
3 tasks done
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.

2 participants