Skip to content

ci: use official Claude PR review comments#31

Merged
MapleEve merged 5 commits into
mainfrom
fix/claude-official-pr-review
May 7, 2026
Merged

ci: use official Claude PR review comments#31
MapleEve merged 5 commits into
mainfrom
fix/claude-official-pr-review

Conversation

@MapleEve
Copy link
Copy Markdown
Owner

@MapleEve MapleEve commented May 7, 2026

Summary

  • Configure the automatic PR review workflow to use anthropics/claude-code-action@v1 without passing a user-owned GitHub token.
  • Remove github_token: secrets.GH_TOKEN, GH_TOKEN env export, and gh pr comment tool access from the no-interaction PR review path.
  • Keep review feedback on the official Claude Code Action / Claude GitHub App integration path. If the Claude GitHub App is not installed for a repository, the workflow should fail instead of posting comments as the repository owner.
  • Use use_sticky_comment and exclude previous automated comments from context to reduce stale self-feedback.

Verification

  • YAML parses successfully.
  • git diff --check passes.
  • BetterAINote targeted CI integration test passes: bun test src/tests/ci-integrations.test.ts.
  • Wrong comments previously posted as MapleEve were removed from the PRs.

Important

This PR intentionally does not use secrets.GH_TOKEN for PR review comments. Official Claude-authored comments require the Claude GitHub App integration for the repository.

Copilot AI review requested due to automatic review settings May 7, 2026 18:13
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 7, 2026

👍 @MapleEve

Thank you for raising your pull request and contributing to voscript.
Please make sure you have followed our contributing guidelines. We will review it as soon as possible.
If you encounter any problems, please feel free to connect with us.
非常感谢您提出拉取请求并为 voscript 做出贡献,请确保您已经遵循了我们的贡献指南,我们会尽快审查它。
如果您遇到任何问题,请随时与我们联系。

@codecov
Copy link
Copy Markdown

codecov Bot commented May 7, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 91.18%. Comparing base (3a9155e) to head (3434f84).
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@           Coverage Diff           @@
##             main      #31   +/-   ##
=======================================
  Coverage   91.18%   91.18%           
=======================================
  Files          76       76           
  Lines        3016     3016           
=======================================
  Hits         2750     2750           
  Misses        266      266           
Flag Coverage Δ
unit 91.18% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@MapleEve MapleEve force-pushed the fix/claude-official-pr-review branch from 660ac1a to 545f575 Compare May 7, 2026 18:15
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates the Claude PR review GitHub Actions workflow to use the official anthropics/claude-code-action PR-review pattern, aiming to let Claude post both a top-level summary and inline comments directly on PRs without using a personal token.

Changes:

  • Switch trigger to pull_request-only (adds reopened, removes workflow_dispatch) and tighten job gating to non-draft PRs from trusted author associations.
  • Replace the previous shell-based “summary fallback” with anthropics/claude-code-action@v1 using track_progress and a prompt that instructs Claude to post comments via gh + MCP inline-comment tooling.
  • Stop passing a personal GH_TOKEN secret into the workflow.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

continue-on-error: true
uses: anthropics/claude-code-action@v1
env:
ANTHROPIC_BASE_URL: ${{ secrets.ANTHROPIC_BASE_URL }}
- name: Checkout repository
if: ${{ env.ANTHROPIC_API_KEY != '' && env.ANTHROPIC_BASE_URL != '' && env.GH_TOKEN_VALUE != '' }}
uses: actions/checkout@v4
uses: actions/checkout@v6
@MapleEve MapleEve merged commit e0e6f06 into main May 7, 2026
8 checks passed
@MapleEve MapleEve deleted the fix/claude-official-pr-review branch May 7, 2026 19:03
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 7, 2026

❤️ Great PR @MapleEve ❤️

The growth of project is inseparable from user feedback and contribution, thanks for your contribution!
项目的成长离不开用户反馈和贡献,感谢您的贡献!

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.

2 participants