feat: implement issue #1390 — [Fleet Monitor] petry-projects/.github-private — .github/workflows/pr-auto-review.yml - #1391
Conversation
…private — .github/workflows/pr-auto-review.yml
🤖 CodeAnt AI — Review Status
|
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
Warning Review limit reached
Next review available in: 40 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (4)
📝 WalkthroughWalkthroughThe PR adds a Dependabot exclusion to the reusable review workflow. It wires workflow changes into developer-lead checks and adds a Python regression test for the reusable workflow reference and guard. ChangesWorkflow guard validation
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related issues
Possibly related PRs
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches 💡 1🛠️ Fix failing CI checks 💡
📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
PR Summary by QodoSkip Dependabot runs for PR Auto-Review workflow (fix #1390)
AI Description
Diagram
High-Level Assessment
Files changed (3)
|
There was a problem hiding this comment.
Code Review
This pull request introduces a new integration test script, test_pr_auto_review_stub.py, which validates that the GitHub Actions workflow pr-auto-review.yml is correctly configured. The script parses the workflow YAML to ensure it references the correct reusable workflow version and includes a guard condition to skip execution for Dependabot-triggered events, preventing failures due to missing secrets. There are no review comments provided, and I have no additional feedback on these changes.
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@tests/dev-lead/integration/test_pr_auto_review_stub.py`:
- Around line 73-80: Update the guard validation in the test around
DEPENDABOT_ACTOR to require an exclusion condition such as github.actor !=
'dependabot[bot]', rather than accepting any condition containing the actor
text; reject equality or other conditions that allow Dependabot to run.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: 49084930-370c-48a2-91d7-f231d8593b48
📒 Files selected for processing (3)
.github/workflows/pr-auto-review.yml.github/workflows/test-dev-lead.ymltests/dev-lead/integration/test_pr_auto_review_stub.py
Code Review by Qodo
Context used✅ Compliance rules (platform):
48 rules 1. Dependabot guard bypass
|
|
CI checks on this PR are still running. Once they complete, re-mention Posted by the donpetry-bot PR-review cascade. |
|
@coderabbitai resolve |
Dev-Lead — review-changes (applied)Changes committed and pushed. |
Auto-dismissed (#617): coderabbitai[bot] CHANGES_REQUESTED on a superseded commit. The bot re-reviews the new head automatically — a valid concern will return as a fresh review.
✅ Action performedComments resolved and changes approved. |
Dev-Lead — review-changes (applied)Changes committed and pushed. |
|
|
CI checks on this PR are still running. Once they complete, re-mention Posted by the donpetry-bot PR-review cascade. |
1 similar comment
|
CI checks on this PR are still running. Once they complete, re-mention Posted by the donpetry-bot PR-review cascade. |
|
Note @don-petry I reviewed this PR and no code changes were needed, but it still has blocking checks or reviews (failing or cancelled checks, or changes-requested reviews), so I cannot mark it done yet. I'll re-check automatically. |
Dev-Lead — waiting on PR blockers (intent: review-changes)PR: #1391 |
donpetry-bot
left a comment
There was a problem hiding this comment.
Automated review — APPROVED ✓
Risk: MEDIUM
Reviewed commit: edbb7b36fbd1d5aab39c2bd76c35e112325183e6
Review mode: triage-approved (single reviewer)
Summary
Adds a Dependabot skip guard to the pr-auto-review.yml caller stub so Dependabot-triggered runs no longer fail on the unavailable GH_PAT_WORKFLOWS secret (fixes the 20% failure rate flagged in #1390), plus a regression test wired into test-dev-lead.yml and template-drift channel repins in seed-repo-template.sh.
Linked issue analysis
Closes #1390 (Fleet Monitor: pr-auto-review.yml at 20% failure rate). Root cause — Dependabot-triggered runs cannot read org secrets, so the reusable's checkout fails with 'Input required and not supplied: token' — is directly addressed by the job-level guard, mirroring the documented #864 precedent in dev-lead-reusable.yml. Dependabot PRs are handled by dependabot-automerge.yml and never need the review dispatch, so skipping is the correct remediation. The issue is substantively addressed.
Findings
- Guard correctness (verified):
github.actor != 'dependabot[bot]' && github.event.pull_request.user.login != 'dependabot[bot]'covers Dependabot-triggeredpull_request/workflow_runevents (actor check),pull_request_reviewevents and human re-runs on Dependabot PRs (PR-author check). On events with nopull_requestpayload the second condition resolves empty ≠ 'dependabot[bot]', so non-Dependabot runs are unaffected. Early Qodo/Gemini findings on an inverted guard and permissive test check were fixed in follow-up commits; all 4 review threads are resolved. - Caller-stub freeze respected: the stub's MUST-NOT list (channel
@pr-auto-review/v1-next, trigger event types, job permissions block) is untouched; only anif:guard was added.caller-stub-freezeandstub-structureCI checks pass. - Regression coverage: new
test_pr_auto_review_stub.pyasserts both the exact guard expression and the channel pin, andtest-dev-lead.ymlnow runs it on any change topr-auto-review.yml(job passed on this PR). - Minor scope note (non-blocking):
seed-repo-template.shrepinsdependabot-rebase→v2-stableandpr-review-mention→v2-stable— template-drift maintenance beyond the literal issue scope, validated by thetemplate-driftandbatschecks, with the bats comment updated in lockstep. - Secret scan: the
run_secret_scanningMCP tool is not available in this environment; the gitleaks CI check passed and no secret-like content appears in the diff.
CI status
All checks on head commit edbb7b3 are green: actionlint, shellcheck, bats, unit-tests, CodeQL (actions + python), gitleaks, SonarCloud quality gate, caller-stub-freeze, stub-structure, template-drift, agent-shield, and the new pr-auto-review-stub job all SUCCESS. Cancelled entries (review/review, dev-lead dispatch/ci-relay, Dismiss) are superseded automation runs with successful counterparts, not code-check failures. CodeRabbit APPROVED; no changes-requested reviews; no unresolved threads.
Reviewed automatically by the PR-review agent (single-reviewer mode: fable 5). Reply if you need a human review.



User description
Closes #1390
Implemented by dev-lead agent. Please review.
CodeAnt-AI Description
Skip Dependabot review runs that cannot access required secrets
What Changed
Impact
✅ Fewer false failures on Dependabot pull requests✅ Dependabot updates complete without missing-token errors✅ Protected automated review workflow configuration💡 Usage Guide
Checking Your Pull Request
Every time you make a pull request, our system automatically looks through it. We check for security issues, mistakes in how you're setting up your infrastructure, and common code problems. We do this to make sure your changes are solid and won't cause any trouble later.
Talking to CodeAnt AI
Got a question or need a hand with something in your pull request? You can easily get in touch with CodeAnt AI right here. Just type the following in a comment on your pull request, and replace "Your question here" with whatever you want to ask:
This lets you have a chat with CodeAnt AI about your pull request, making it easier to understand and improve your code.
Example
Preserve Org Learnings with CodeAnt
You can record team preferences so CodeAnt AI applies them in future reviews. Reply directly to the specific CodeAnt AI suggestion (in the same thread) and replace "Your feedback here" with your input:
This helps CodeAnt AI learn and adapt to your team's coding style and standards.
Example
Retrigger review
Ask CodeAnt AI to review the PR again, by typing:
Check Your Repository Health
To analyze the health of your code repository, visit our dashboard at https://app.codeant.ai. This tool helps you identify potential issues and areas for improvement in your codebase, ensuring your repository maintains high standards of code health.
Summary by CodeRabbit
Bug Fixes
Tests