ci: bump actions/checkout to v7 across all workflows - #17
Conversation
actions/checkout was pinned to v4 in claude.yml and claude-code-review.yml (both flagged as stale — Node.js 20 deprecation warnings), and to v5 in ci.yml. The actual current latest major is v7, so bump all three to v7 rather than stopping at v5. v7 adds a new opt-in gate (`allow-unsafe-pr-checkout`) that refuses to check out fork PR code under `pull_request_target` or `workflow_run` by default, to prevent "pwn request" style vulnerabilities. claude-code-review.yml's "Check out PR head" step does exactly that (pull_request_target, checking out `github.event.pull_request.head.repo.full_name` from a fork), so `allow-unsafe-pr-checkout: true` is added there to preserve existing behavior. This is safe in this workflow because the job is already gated to the trusted jnasbyupgrade fork only, the checkout is read-only (persist-credentials: false), and PR code is never built or executed. v5's Node 24 runtime bump and v6's credential-persistence rework (stored in a separate file under $RUNNER_TEMP rather than .git/config) require no workflow changes per upstream release notes. anthropics/claude-code-action stays pinned at v1 in both Claude workflows — checked releases/tags on the action's repo and no v2 exists yet. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Verification results
This is expected and not caused by this PR. Correcting something from this PR's own description: I called #15 an "unrelated checkout-failure fix" for this same step, but reading #15's diff, it's not unrelated - it adds the identical Per #15's own findings, full verification of the checkout fix requires merging to master and observing a subsequent PR's
|
Summary
Audited every
uses:line in.github/workflows/*.ymland bumped staleactions/checkoutpins.anthropics/claude-code-action@v1was also checked and left as-is (no v2 exists).Bumps made:
.github/workflows/claude.yml(line ~39):actions/checkout@v4→@v7.github/workflows/claude-code-review.yml(line ~81):actions/checkout@v4→@v7, plus addedallow-unsafe-pr-checkout: trueto that step (see below — required, not cosmetic).github/workflows/ci.yml(line ~23):actions/checkout@v5→@v7The task originally assumed
v5(already used byci.yml) was current, butactions/checkout's actual latest major is v7, so all three were bumped to v7 rather than stopping at v5.anthropics/claude-code-action@v1inclaude.ymlandclaude-code-review.yml: checkedgh api repos/anthropics/claude-code-action/releasesand.../tags— latest isv1.0.184under the floatingv1tag, nov2release or tag exists. Left unchanged.Changelog review before bumping
Checked
actions/checkoutrelease notes for v5, v6, and v7 (not just the version string):persist-credentialsnow stores creds in a separate file under$RUNNER_TEMPinstead of.git/config. Per upstream notes, "no workflow changes required — git fetch, git push, etc. continue to work automatically." Verified none of the three workflows rely on.git/config-based credential persistence directly.allow-unsafe-pr-checkout— that refuses to check out fork PR code when the workflow trigger ispull_request_targetorworkflow_run, unless explicitly set totrue(upstream: prevents "pwn request" vulnerabilities). This is directly relevant here:claude-code-review.yml's "Check out PR head" step runs underpull_request_targetand explicitly checks outgithub.event.pull_request.head.repo.full_name— exactly the pattern v7 blocks by default. Without the opt-in, that step would start failing on every PR after this bump. Addedallow-unsafe-pr-checkout: truewith a comment explaining why it's safe in this specific workflow (job already gated to the trustedjnasbyupgradefork only, checkout ispersist-credentials: false/read-only, PR code is never built or executed).No behavior-affecting change was found for
ci.ymlorclaude.yml's checkout steps (neither usespull_request_target/workflow_runwith a fork checkout).Verification
yaml.safe_load).jnasbyupgrade/extension_toolsand watching a live CI run onci.yml(push trigger) to confirm theactions/checkout@v4Node.js 20 deprecation warning is gone from the "Check out the repo" step logs.claude.ymlandclaude-code-review.ymldon't produce meaningful log output for this specific check outside their real trigger contexts (@claudemention /pull_request_targetreview), so the checkout-step behavior there is confirmed via the changelog review above rather than a live log capture in this PR's own CI run. Will update this PR with results once theci.ymlrun completes.Expected future conflict
Branch
track-progress-claude-review(PR #15) is concurrently editingclaude-code-review.ymlfor an unrelated checkout-failure fix. This branch is independent, based on currentupstream/master, and will very likely conflict with #15 on merge/rebase — expected, not addressed here.