Gate PRs with an automated review instead of a human one - #2230
Gate PRs with an automated review instead of a human one#2230defangdevs wants to merge 1 commit into
Conversation
|
Warning This pull request changes a CodeRabbit configuration file. Because it comes from a fork or its author is not a repository collaborator, reviews use only the configuration from the target branch. The proposed configuration will take effect after it is merged. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
Included review availability: 3 reviews are currently available. Your included PR review attempts over the past 7 days set your current allowance at 5 reviews per hour. 📝 WalkthroughWalkthroughAdded a shared CodeRabbit configuration. It enables request-based change workflows, limits pre-merge overrides to requested reviewers, sets selected checks to warnings, and disables docstring checks. ChangesCodeRabbit configuration
Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk: ⚪ Minimal · up to This change enables automated review gating for pull requests; no actionable merge-blocking risk remains after normal checks and review. Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
Comment |
|
Superseded by CodeRabbit Organization → Global Overrides, which now carries this policy org-wide. That layer outranks a repo Verified on DefangLabs/defang-github-action#58 with The CI half of the change is unaffected: DefangLabs/defang-github-action#58 and DefangLabs/defang-mvp#3203 stay open. |
|
Tip For best results, initiate chat on the files or code changes.
The separate CI work remains tracked in DefangLabs/defang-github-action#58 and DefangLabs/defang-mvp#3203. ✏️ Learnings added
You are interacting with an AI system. |
Why
Every PR in this org needs 1 approving review (org ruleset "Protect Default Branches"), and in practice @lionello is the only approver. Most PRs are now agent-authored, so human review is the bottleneck on velocity.
This makes CodeRabbit the approving reviewer instead:
request_changes_workflow: true— CodeRabbit requests changes when it finds a problem and approves when the problem is fixed. Today it only comments, so it gates nothing.pre_merge_checks.override_requested_reviewers_only: true— the PR author can not dismiss a failed check, so an agent can not wave through its own PR.warning. Raise one toerrorwhen we want it to block a merge.An app approval already satisfies the rule today:
dependabot-automerge.ymlmerges with an approval fromgithub-actions[bot]. Nothing in the ruleset has to change for this to work.The ruleset itself keeps
requiredReviewThreadResolution: true, so CodeRabbit comments must still be resolved before a merge.Scope
The same file goes into every active DefangLabs repo. A CI gate (one standard
cicheck per repo, required through the org ruleset) is the second layer and lands separately — therequire-ci-gateruleset indefang-mvp/pulumi/infrastructure/githubx.ts.Verify
After merge, open a throw-away PR and confirm
coderabbitai[bot]posts a review with stateCHANGES_REQUESTEDorAPPROVED(not justCOMMENTED), and that the approval satisfies the branch rule.Summary by CodeRabbit