Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/workflows/review.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ jobs:
review:
name: Cassandra Review
runs-on: ubuntu-latest
if: github.event.pull_request.head.repo.full_name == github.repository
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

The addition of the repository check is excellent. This ensures the workflow doesn't trigger on fork PRs where secrets like GEMINI_API_KEY are missing, preventing unnecessary CI failures and improving the resilience of our pipeline.

permissions:
contents: read
pull-requests: write
Expand All @@ -19,6 +20,7 @@ jobs:
- name: Run Cassandra AI Review
uses: menny/cassandra@v0.2.0
with:
reviewer_github_token: ${{ secrets.AI_CODE_REVIEW_GH_TOKEN }}
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

We are introducing a classic Personal Access Token (PAT) via secrets.AI_CODE_REVIEW_GH_TOKEN. Unless this specific action requires a PAT to trigger subsequent workflows (which the default GITHUB_TOKEN cannot do) or to bypass specific API limitations, we should prefer secrets.GITHUB_TOKEN. Classic PATs are long-lived and often over-privileged compared to the short-lived, repo-scoped default token.

provider_api_key: ${{ secrets.GEMINI_API_KEY }}
# The base branch to compare against (defaults to main)
base: ${{ github.event.pull_request.base.sha }}
Expand Down
Loading