fix(pr-policy): make metadata checks advisory, block only on clinical governance#967
Conversation
Follow-up to the classification narrowing: make the PR Policy check stop blocking PRs for metadata nits. evaluatePullRequestPolicy now returns a warnings[] array alongside errors[]: - errors[] (blocking): only a clinical-risk PR with a missing or incomplete Clinical Governance Preflight fails the check. - warnings[] (advisory): title, Summary, Verification, UI verify:ui, and Risk and rollout expectations are surfaced as warnings that never fail the check or block a merge. The workflow emits warnings via core.warning and only calls setFailed on blocking clinical-governance errors. Self-tests updated to assert the block-vs-warn split. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014MG846R4YM51NojUf9XthF
|
This pull request has been ignored for the connected project Preview Branches by Supabase. |
|
Warning Review limit reached
Next review available in: 29 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: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Summary
PR Policycheck was still hard-failing PRs for metadata nits (missing/empty Summary or Verification, noverify:uievidence, incomplete Risk and rollout). This makes those advisory warnings instead of blocking failures, so the check stops getting in the way.evaluatePullRequestPolicy()now returns awarnings[]array alongsideerrors[]:errors[](blocking): only a genuine clinical-risk PR with a missing or incomplete## Clinical Governance Preflightfails the check.warnings[](advisory): title quality,## Summary,## Verification, UIverify:uievidence, and## Risk and rolloutare surfaced as warnings that never fail the check or block a merge..github/workflows/pr-policy.yml) now emits warnings viacore.warningand only callscore.setFailedfor blocking clinical-governance errors. The run summary reports both counts.Verification
npm run check:pr-policy— self-test (updated to assert the block-vs-warn split) +check-pr-policy-workflow.mjsworkflow-contract guard both pass.npx eslint scripts/pr-policy.mjsclean;npx prettier --checkclean on both changed files.ok: truewith warnings; a clinical-risk PR (src/lib/answer-synthesis.ts) with no governance section →ok: false.verify:pr-local/verify:ui— this is a CI metadata-policy script only, with no app runtime, UI, or provider surface; the targeted self-test + lint above are the relevant gate.Risk and rollout
pr-policy.ymlruns fromgithub.workflow_sha(base/main), so the new behavior applies to open PRs only after this merges tomain.Notes
requiredClinicalGovernanceItems(still exported for the dormantsync-pr-policy-bodyjob) or to the workflow's trusted-checkout contract, soscripts/check-pr-policy-workflow.mjsstays green.🤖 Generated with Claude Code
Generated by Claude Code