Skip to content

Fix key name for Claude Code Review action - #611

Merged
laffer1 merged 1 commit into
masterfrom
laffer1-patch-1
Jun 5, 2026
Merged

laffer1 merged 1 commit into
masterfrom
laffer1-patch-1

Conversation

@laffer1

@laffer1 laffer1 commented Jun 5, 2026 •

Copy link
Copy Markdown
Member

Summary by Sourcery

CI:

  • Correct the input parameter name for the Claude code review GitHub Action to use the claude_code_oauth_token secret.

@gemini-code-assist

Copy link
Copy Markdown

Note

Gemini is unable to generate a review for this pull request due to the file types involved not being currently supported.

@laffer1
laffer1 merged commit e9816e1 into master Jun 5, 2026
7 of 8 checks passed
@sourcery-ai

sourcery-ai Bot commented Jun 5, 2026 •

Copy link
Copy Markdown
Contributor
Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Updates the GitHub Actions workflow for Claude Code Review to use the correct input key name for the OAuth token, aligning with the expected action interface.

File-Level Changes

Change Details Files
Corrected the input parameter name for the Claude Code Review GitHub Action to match the action's expected key.
  • Replaced the anthropic_api_key input with claude_code_oauth_token in the Claude code review workflow job.
  • Ensured the workflow still sources the token from secrets.CLAUDE_CODE_OAUTH_TOKEN while using the new input name.
.github/workflows/claude-code-review.yml

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@laffer1
laffer1 deleted the laffer1-patch-1 branch June 5, 2026 01:39
@claude

claude Bot commented Jun 5, 2026 •

Copy link
Copy Markdown

Claude finished @laffer1's task —— View job


Reviewing PR #611: Fix key name for Claude Code Review action

Todo List:

  • Read the changed workflow file to understand the diff
  • Review against MidnightBSD mports criteria
  • Provide inline comments if issues found
  • Summarize overall verdict

Review Findings

This PR created a new GitHub Actions workflow for Claude Code Review. While most MidnightBSD mports review criteria don't apply to workflow files, I found one critical inconsistency:

Issue Found

Line 53: In the manual trigger step, the input parameter is incorrectly named anthropic_api_key instead of claude_code_oauth_token:

# Manual step (INCORRECT):
with:
  anthropic_api_key: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}

# Automatic step (CORRECT):  
with:
  claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}

This inconsistency means the manual workflow dispatch will fail because it uses the wrong input parameter name for the Claude Code Action.

Security & Correctness Assessment

✅ Security: No embedded credentials, proper use of GitHub secrets
✅ Workflow syntax: Valid GitHub Actions YAML
❌ Correctness: Inconsistent parameter naming between automatic and manual steps
✅ Permissions: Appropriate permissions scope (contents: read, pull-requests: write, id-token: write)

Overall Verdict

NEEDS FIX: While the PR title claims to "Fix key name for Claude Code Review action," it actually introduces an inconsistency. The automatic step correctly uses claude_code_oauth_token, but the manual step still uses the incorrect anthropic_api_key parameter name.

Recommendation: Line 53 should be changed from anthropic_api_key: to claude_code_oauth_token: to match the automatic step and ensure the manual workflow dispatch functions correctly.


@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Hey - I've reviewed your changes and they look great!


Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

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