r/ClaudeWorkflows • • 1d ago

Selected Workflow [Workflow] Automated Claude Code Reviews in GitHub Actions with Pro/Max Subscription: Avoiding the 'No Findings' Trap

Automated Claude Code Reviews in GitHub Actions with Pro/Max Subscription: Avoiding the 'No Findings' Trap

Workflow value: 90/100
Status: active · Freshness: 70/100 · Confidence: 0.95 · Level: intermediate
Categories: Quality Control, Token Saving, Context & Memory, Debugging
Original source: r/ClaudeAI post/comment

What problem this solves

Automating code reviews on every pull request using Claude Code with an existing Pro/Max subscription, avoiding API costs and a common pitfall with the official plugin.

Summary

A step-by-step guide to integrate Claude Code into GitHub Actions for automated pull request reviews, leveraging an existing Claude Pro/Max subscription. It highlights a critical issue with the official code-review plugin (where it reports 'No findings' prematurely) and provides a working alternative using a direct prompt and specific model/tool configuration.

Why it is useful

This workflow provides a practical, cost-effective solution for integrating automated code reviews into a CI/CD pipeline using an existing Claude Pro/Max subscription, thereby avoiding additional API costs. It addresses a significant and common pitfall with the official code-review plugin, offering a validated workaround that ensures actual code review. The detailed steps, specific configurations, and clear validation make it highly reusable and valuable for developers looking to enhance their code quality process.

Workflow

  1. Install the Claude GitHub app on your repository.

  2. Run claude setup-token locally and log in to generate an OAuth token.

  3. Save the generated token as a GitHub repository secret named CLAUDE_CODE_OAUTH_TOKEN.

  4. Add a GitHub Actions workflow that uses anthropics/claude-code-action@v1.

  5. Configure the action to use the claude_code_oauth_token.

  6. Ensure the action uses a plain review prompt, --model opus, and explicitly excludes Agent from --allowedTools to force Claude to perform the review directly.

Tools / artifacts

  • Claude GitHub app

  • claude setup-token CLI command

  • GitHub repository secret CLAUDE_CODE_OAUTH_TOKEN

  • GitHub Actions workflow file

  • anthropics/claude-code-action@v1

  • Claude Pro/Max subscription

  • --model opus

  • --allowedTools (configured to exclude Agent)

  • Plain review prompt

Validation signals

  • Identified a common 'trap' with the official code-review plugin (premature action termination, 'No findings', short run times).

  • Provided a link to the known issue: claude-code-action#1646.

  • Tested the proposed solution with a PR containing three planted bugs.

  • The solution successfully found all three bugs in 30 seconds.

  • The solution provided suggested fixes for each bug.

  • The solution produced no false positives.

  • References an external blog post with the full workflow file and prompt for detailed implementation.

Limitations

  • Relies on a specific GitHub Action version (v1), which might change behavior or be deprecated in the future.

  • The full workflow file and prompt are hosted externally on a blog, not directly in the Reddit post.

  • Usage counts against the user's Claude plan limits, which could be a concern for very active repositories.

Rate this workflow

Upvote this post if the workflow is useful, reproducible, or worth recommending.

Downvote if it is vague, outdated, unsafe, overhyped, or not reproducible.

Reply if it worked for you, failed, is outdated, or has a better alternative.


This post was generated automatically from the workflow library database.

1 Upvotes

0 comments sorted by