Skip to content

ci(pr-pipeline): let the trust-gate hold pass vendor tag-to-tag bumps - #18643

Merged
kyle-sexton merged 4 commits into
mainfrom
ci/vendor-tag-ref-swap
Nov 24, 2026
Merged

kyle-sexton merged 4 commits into
mainfrom
ci/vendor-tag-ref-swap

Conversation

@kyle-sexton

@kyle-sexton kyle-sexton commented Nov 24, 2026 •

Copy link
Copy Markdown
Member

Summary

Follow-up to #18605. CI Status's trust-gate hold (ref_swap jq in .github/workflows/pr-require-checks.yml) accepted only 40-hex ref swaps, so a Dependabot bump such as actions/checkout@v6 to @v7 in a lane workflow still waited for a person after the verdict job learned to treat it as a pin swap.

Fix

This delivers #18604's trust-gate items (proposed work 2 and 3, and the four open acceptance criteria):

  • ref_swap now also captures a version tag (vN, vN.N, vN.N.N, the exact shape TAGGED_USES in dependency-classify.mjs accepts) for an official vendor owner (actions, github, dependabot, microsoft, azure, anthropics, openai, case-insensitive, the same list as VENDOR_ACTION_OWNERS). Both sides of a pair must be the same kind: a SHA never pairs with a tag. Same action path and indent are still required.
  • The tag read checks a tag ref by name (refs/tags/<tag> must exist in the action's repository); a SHA ref keeps the tagged-commit check. The merge.dependabot.trusted-action-owners check and the lanes App verdict path still apply after the shape check, unchanged, as does the hold message text review-dependency.mjs matches.
  • scripts/ci-review-lanes.test.sh: new cases for a vendor tag-to-tag bump passing (listed owner, the repository's own owner list, mixed-case Azure), an unlisted vendor owner waiting for a merge verdict, and holds for a missing tag, first-party tag swap, third-party tag swap, tag to branch, tag to non-version tag, path change, SHA to tag and tag to SHA. The vendor tag rows the git stub returns come from a real git ls-remote --tags of a throwaway repository the test builds with lightweight and annotated version tags. Two existing "mixed bump" cases used actions/checkout tag swaps as their non-passing half; they now use a third-party action so they still test what they name.
  • apply-dependency-verdict.mjs header comment, inline comment and log line no longer say only "full-SHA pin swap".
  • pr-pipeline README rule text and a changelog fragment.

Basis: tag shape and owner list copied from .github/scripts/pr-unblock/dependency-classify.mjs:225-228 (merged in #18605); owner list from architecture docs/owner-decisions.md L351.

Loosened checks

  • CI Status trust-gate hold, ref_swap in .github/workflows/pr-require-checks.yml: a Dependabot PR whose only workflow change moves an official vendor action from one version tag to another (same action path, new tag present in the repository) now clears the hold the same way a full-SHA swap to a tagged commit does. Reason: owner decision D3, architecture docs/owner-decisions.md L351, owner verbatim: "official vendor like Microsoft or Anthropic or OpenAI ... those I don't want pinned". First-party and third-party tag swaps, and every other shape, keep the hold.

Verification

  • bash scripts/ci-review-lanes.test.sh: PASS=339 FAIL=0 at 34fd6fba, and again PASS=339 FAIL=0 at fdbf7ea6 after the vendor tag rows moved to real git ls-remote --tags output.
  • node --test --test-concurrency=4 on apply-dependency-verdict, clear-escalations, review-dependency, dependency-dispatch and dependency-classify tests: 337 pass, 0 fail.
  • node scripts/sync-credential-legs.mjs --check, python3 scripts/sync-hold-floor.py --check, actionlint .github/workflows/pr-require-checks.yml: all exit 0.

Related

Closes #18604

🤖 Generated with Claude Code

CI Status's trust-gate ref_swap jq accepted only 40-hex ref swaps, so a
Dependabot bump such as actions/checkout@v6 to @v7 in a lane workflow
waited for a person even after #18605 taught the verdict job to treat it
as a pin swap. It now also accepts an official vendor action (actions,
github, dependabot, microsoft, azure, anthropics, openai, any case)
moving between version tags (vN, vN.N, vN.N.N) with the same action
path, once the new tag exists in the action's repository. A SHA never
pairs with a tag; first-party and third-party tag swaps keep the hold.
Owner decision D3, architecture docs/owner-decisions.md L351.

Closes #18604

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

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

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-24T00:26:09.382248Z 34fd6fb 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.

@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: 34fd6fba9a

ℹ️ 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 scripts/ci-review-lanes.test.sh Resolved
@github-actions

github-actions Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

claude-security-review reviewed 1bed9014d558d52e522777cb486bf351bc43a485: read 5 of 5 changed file(s); 0 finding(s), 0 as inline comments.

Security review: PR #18643 at 1bed9014

No security issues found. This lane already reviewed an earlier head, so this review reports blocking issues only.

Scope. I read every hunk of all 5 changed files in the full diff. I also read the trust-gate step in .github/workflows/pr-require-checks.yml around the change (L7549-L7621) to see what it gates. Since the earlier review at fdbf7ea6, the only new change is in scripts/ci-review-lanes.test.sh. The test now sources the shared scripts/test-git-helpers.sh and builds the throwaway tag repository through git_init_test_repo and git_test_config. Hooks stay off (core.hooksPath=/dev/null), ls-remote reads only a local path the test created, and no untrusted input reaches it.

Trust-gate hold (ref_swap, pr-require-checks.yml#L7579-L7600).

  • Throughput-phase exemption. The change narrows the owner's trust-path hold for Dependabot version-tag bumps of official vendor actions. Under the owner threat model that is a named friction hold, so its weakening is not a finding.
  • Who reaches it. The path is still gated on AUTHOR_ID = 49699333, Dependabot (L7565).
  • Which tags pass. A tag ref matches only v[0-9]+(\.[0-9]+){0,2}, and only when the owner is one of the seven vendor owners, compared in lower case (L7580). For any other owner the select empties ref_swap, so the length == 1 checks fail and the hold stays. This covers the first-party melodic-software too.
  • No mixing. Both sides of a pair must be the same kind (L7592), so a SHA never pairs with a tag. A 40-hex ref can never start with v, so the kind test is sound.
  • Tag read. The awk check needs refs/tags/<tag> to exist exactly in the action's repository; a SHA still needs a tag that points to it. The $ref and $repo values passed to awk -v and to the ls-remote URL are limited by the capture regex, so there is no injection path.
  • Unchanged checks. The merge.dependabot.trusted-action-owners check and the lanes App verdict path after it are unchanged.

Other files. The changes to apply-dependency-verdict.mjs are comment and log-text only; pinSwapRefusal is not changed in this diff. The README and changelog fragment are prose that matches the code.

  • Removed friction hold (throughput phase, not a finding): the trust-path hold now lets through a Dependabot version-tag bump of an official vendor action.

Spend: none beyond the normal CI test run.

critical-findings: 0

@github-actions

github-actions Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

claude-review reviewed 1bed9014d558d52e522777cb486bf351bc43a485: read 5 of 5 changed file(s); 0 finding(s), 0 as inline comments.

Code review (blocking only): no findings

This lane already reviewed an earlier head (fdbf7ea6), so this review reports only blocking findings. I read all five changed files in the full diff. The new commit 1bed9014 changes one thing, in scripts/ci-review-lanes.test.sh: the throwaway vendor-tag repository is now built with the shared helpers. The test sources scripts/test-git-helpers.sh and uses git_init_test_repo, and vgit is now git_test_config "$vtags" -c core.hooksPath=/dev/null "$@".

What I checked by reading (I ran nothing):

  • The helper accepts these calls. git_test_config runs git -C <dir> with the fixture identity, commit and tag signing off, gc.auto=0 and maintenance.auto=false, then the caller's arguments (test-git-helpers.sh L53-L69). So the extra -c core.hooksPath=/dev/null comes before the subcommand, where git accepts it. The helper refuses any directory that is not a repository root, and git_init_test_repo creates $vtags/.git before the first vgit call. The commit and tag -a calls therefore pass that check.
  • The build stays outside the checkout. git_init_safe refuses a path inside the current repository. $vtags is under the mktemp -d root, so a normal run is accepted, and any refusal falls through to the existing fail branch.
  • Sourcing the helper changes the suite's git environment. At source time it clears GIT_DIR and related variables, sets GIT_CONFIG_GLOBAL to /dev/null unless already set, sets GIT_CONFIG_NOSYSTEM=1, and exits if TMPDIR is inside a repository (L34-L44). These settings now apply to the whole suite. The git calls I read in it do not depend on global or system config: the stubbed git under expect, and the local ls-remote of the fixture.
  • The tag rows and the cases that use them are unchanged. The repository still gets lightweight tags v1 and v1.0.265 and annotated tags v2 and v1.0.266. The refs/tags/v2^{} check still fails closed.

Closing issue #18604: the trust-gate criteria were met at the earlier reviews. The ref_swap jq widening, the same-kind pairing check, the tag-by-name awk check, the apply-dependency-verdict.mjs wording and the test cases are unchanged by this push. The PR body's PASS=339 and node --test results are the author's claims; I did not verify them.

Loosened checks: this push changes only how the test fixture is built and loosens nothing. The PR's one loosening is the trust-gate ref_swap change. Both the closing issue (owner decision D3) and the PR body's ## Loosened checks section give its reason. The prompt had no loosened_check_verdict:, loosened_check_patterns: or loosened_check_decision_record: lines. I used fail with no consumer entries, and I did not check the citation requirement.

Loosened checks would be marked: fail (default; no wrapper setting); patterns: 0

Verifier dropped 0 of 0 candidates.

@github-actions

github-actions Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

PR body contract — issue linkage

This PR body conforms to the issue-linkage contract. Nothing to do.

@github-actions github-actions Bot added the needs-issue-linkage Pull request body has no issue linkage line; set by the check-contract step, advisory. label Nov 24, 2026
@melodic-automation-lanes melodic-automation-lanes Bot added the needs-session A pr-unblock stop a session builder takes: a change the lane cannot make. Not an owner stop. label Nov 24, 2026
@melodic-automation-lanes

Copy link
Copy Markdown
Contributor

The pr-unblock lane stopped address-feedback on this pull request: the pull request changes .github/workflows/, which the lane token cannot push, so the lane does not address its review threads. The lane labels it needs-session for a session builder, who makes the change this lane cannot, and the run ends in a failing pr-unblock/address-feedback status on the head the lane gated.

When a retry on this head can change the outcome, the lane runs one on its own, up to its per-head cap, and edits this comment if it stops again; a run that does not stop clears the status. When no retry can (a review thread the lane does not take or settle, or a failing check after the retries are spent), a person resolves the threads or gets the checks green, then dispatches the workflow below: that run finds the cause gone and clears the status. On a pull request the lanes App opened, the dispatchers start that run once per stop; on any other, a person does. A new commit to the branch starts clean.

To run it again on this head now, dispatch the pr-unblock workflow:

gh workflow run pr-unblock.yml -R melodic-software/claude-code-plugins -f pr-number=18643 -f activity=address-feedback

The vendor tag-swap cases read a hand-built `refs/tags/v2` row. The test
now builds a throwaway repository with lightweight and annotated version
tags and appends its real `git ls-remote --tags` output to the stub's
tag list, so the rows have the producer's shape (docs/review/tests.md).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@github-actions github-actions Bot removed the needs-issue-linkage Pull request body has no issue linkage line; set by the check-contract step, advisory. label Nov 24, 2026
@kyle-sexton

Copy link
Copy Markdown
Member Author

Owner: active, left: fix the fixture-git-isolation Lint Shell failure in scripts/ci-review-lanes.test.sh, then re-queue. ETA 10:45 PM EST.

kyle-sexton and others added 2 commits November 23, 2026 21:58
…t helpers

The throwaway repository behind the vendor tag rows ran git with the
inherited git environment and host config, which fixture-git-isolation
fails. The suite now sources scripts/test-git-helpers.sh and builds the
repository with git_init_test_repo and git_test_config.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@kyle-sexton
kyle-sexton added this pull request to the merge queue Nov 24, 2026
@kyle-sexton

Copy link
Copy Markdown
Member Author

PR lane (desk): last push 03:00Z, past the 03:45Z ETA above (Lint Shell fixture fix in scripts/ci-review-lanes.test.sh). Still on it? Reply here with a new ETA, or post 'Owner: PR lane may take over' and the desk PR lane finishes it.

@melodic-automation-lanes melodic-automation-lanes Bot removed the needs-session A pr-unblock stop a session builder takes: a change the lane cannot make. Not an owner stop. label Nov 24, 2026
Merged via the queue into main with commit 82532c0 Nov 24, 2026
172 of 175 checks passed
@kyle-sexton
kyle-sexton deleted the ci/vendor-tag-ref-swap branch November 24, 2026 04:02
@github-actions github-actions Bot added the merge-path: owner-agent Post-merge accounting record (README.md, Merge paths) label Nov 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merge-path: owner-agent Post-merge accounting record (README.md, Merge paths)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Auto-merge Dependabot bumps of official vendor action tags like full-SHA pin swaps

1 participant