@beta checks out the PR head branch by name from origin, so @claude on a
fork PR fails with 'couldn't find remote ref' -- or, when origin has a
branch with the same name, silently checks out the wrong code. v1 fetches
fork PRs via refs/pull/N/head.
Migrate inputs per the v1 migration guide: direct_prompt -> prompt (with
REPO/PR NUMBER context), model -> claude_args --model, and give the
automatic review its comment tools. track_progress + use_sticky_comment
keep the existing single progress comment. Drop commented-out examples
that use removed v0 inputs.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VCRwrpJY25CRtyTcu6aD8V
Summary
On
@beta,@claudedoesn't work on fork PRs. The action checks out the PR's head branch by name from origin, which causes two problems:fatal: couldn't find remote ref(fix(ast): preserve IS NOT NULL and ClickHouse parametric aggregate params in output #529, feat(parser,ast): preserve parenthesized expressions (fix #519) #532–feat(parser): ClickHouse array/tuple element access via dot (d.1) #535).v1 detects fork PRs (
isCrossRepository) and fetches them throughrefs/pull/N/head(src/github/operations/branch.ts), which fixes both.Changes, following the v1 migration guide:
@beta→@v1inclaude.ymlandclaude-code-review.ymlmodel:→claude_args: --model claude-sonnet-5-5direct_prompt→prompt, withREPO/PR NUMBERcontext (v1 requires it for PR reviews)track_progress+use_sticky_commentkeep the single progress comment.--allowedToolslets Claude post inline and top-level comments, since v1 automation mode doesn't comment by default.track_progressis set only forpull_requestevents, because v1 throws onworkflow_dispatch.The fork-PR skip from #538 stays in place. Fork PRs still get no secrets on
pull_requestevents.Test Plan
action.ymlclaude-reviewrun (a same-repo PR) posts a review on v1@claudeon a fork PR (e.g. feat(parser): ClickHouse array/tuple element access via dot (d.1) #535) checks out the fork head and repliesBreaking Changes
None for contributors. The review comment may be formatted slightly differently under v1.
🤖 Generated with Claude Code
https://claude.ai/code/session_01VCRwrpJY25CRtyTcu6aD8V