feat: Phase 3 label validation enforcement - #1613
Conversation
- Validates labels before issue/PR creation - Enforces canonical prefixed labels (type:, status:, priority:, area:, meta:, etc.) - Enforces one-hot per family (except meta:, comp:, lang: which allow multiple) - Requires type:* label for all issues/PRs - Provides clear error and warning messages - Includes comprehensive unit tests (12+ test cases)
|
Warning Review limit reached
Next review available in: 15 minutes You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. 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: Repository YAML (base), Organization UI (inherited) Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (3)
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 |
| */ | ||
|
|
||
| const fs = require('fs'); | ||
| const path = require('path'); |
| // ============================================================================ | ||
|
|
||
| const FAMILIES_ALLOW_MULTIPLE = ['meta', 'comp', 'lang']; | ||
| const REQUIRED_FAMILIES = ['type']; |
|
|
||
| for (const label of labels) { | ||
| if (bareLabels.includes(label)) { | ||
| const family = getFamily(label); |
|
🚫 This PR description is missing required template content. Missing required section(s): Linked issues, Changelog, Global DoD checklist Please update the PR body using one of the repository PR templates:
Empty placeholders, unchecked checklist boxes, and stub issue references do not count. |
Phase 3: Enforce Validation — Add Workflow-Level Validation
Status: Implementation complete, ready for review
Summary
Implements pre-creation label validation to prevent new bare-label violations. All issues/PRs will now be validated against the canonical label system.
Changes
Validation Script (new):
.github/scripts/validation/validate-labels-before-creation.cjsUnit Tests (new):
.github/scripts/validation/__tests__/validate-labels-before-creation.test.cjsValidation Workflow (new):
.github/workflows/validate-issue-labels.ymlRelated
🤖 Generated with Claude Code