Skip to content

feat: PR Creation Agent — Skill 2: route-pr-template (Complete) - #2008

Merged
ashleyshaw merged 2 commits into
developfrom
feat/pr-route-template-skill
Aug 18, 2026
Merged

feat: PR Creation Agent — Skill 2: route-pr-template (Complete)#2008
ashleyshaw merged 2 commits into
developfrom
feat/pr-route-template-skill

Conversation

@ashleyshaw

@ashleyshawashleyshaw commented Aug 18, 2026

Copy link
Copy Markdown
Member

Linked issues

Closes#1870

Changelog

Added

  • PR Creation Agent Phase 3 Skill 2: route-pr-template (190 LOC) with secure YAML parsing and metadata extraction
  • Template routing configuration system supporting 25+ branch types
  • Comprehensive test suite (23 tests, 97% coverage) for template discovery and metadata validation

Changed

  • PR Creation Agent to support multi-skill pipeline architecture
  • Template metadata extraction to identify required sections (Linked issues, Changelog, Checklist)

Summary

Complete implementation of PR template routing skill for PR Creation Agent Phase 3.

Deliverables

  • route-pr-template.js (~190 LOC): Routes PRs to templates based on branch type, loads YAML routing config, extracts metadata
  • route-pr-template.test.js: 23 tests, 100% passing, 97%+ code coverage
  • Security: Safe YAML parsing with DEFAULT_SAFE_SCHEMA
  • Integration: Works with Skill 1 output (branchType), feeds Skill 3 (template metadata)

Bug Fixes

  • Fixed branch naming violation: renamed from feat/route-pr-template to feat/pr-route-template-skill per {type}/{scope}-{short-title} format
  • Fixed unused variable in test: removed unused result variable in "should load config from default path" test
  • Resolved merge conflicts from develop divergence

Test Coverage

  • 23 unit tests covering input validation, config loading, routing, file reading, metadata extraction, error handling
  • 97.05% statement coverage, 94.44% branch coverage, 100% function coverage
  • All 25+ documented branch types tested
  • Error scenarios validated

Phase Progress

  • Phase 3: 2/6 skills complete (33%)
  • Skill 1 (validate-branch-name): ✅ Complete (104 LOC, 39 tests)
  • Skill 2 (route-pr-template): ✅ Complete (190 LOC, 23 tests)
  • Skills 3-6: Ready for implementation

Checklist (Global DoD / PR)

  • All AC met and demonstrated
  • Tests added/updated (unit/E2E as appropriate)
  • Accessibility checklist completed (where relevant):
    • Semantic HTML and heading order verified
    • Keyboard navigation and visible focus states verified
    • ARIA used only where needed
    • Contrast and non-colour cues reviewed (WCAG 2.2 AA or higher)
  • Docs/readme/changelog updated (if user-facing)
  • Security checklist completed (where relevant):
    • Untrusted input validated and sanitised
    • Output escaped for its rendering context
    • Privileged actions enforce nonce and capability checks
    • No secrets/sensitive data introduced; OWASP risks reviewed
  • Code/design reviews approved
  • CI green; linked issues closed; release notes prepared (if shipping)

@ashleyshaw
ashleyshaw enabled auto-merge (squash) August 18, 2026 13:40
@coderabbitai

coderabbitaiBot commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

@ashleyshaw, you've reached your PR review limit, so we couldn't start this review.

Next review available in:6 minutes

Limit details: You’ve used the included review currently available.

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 @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

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 within each organization.

For paid Pro and Pro+ reviews, CodeRabbit uses a developer's included PR review attempts over the past 7 days to set the current hourly allowance. At typical activity levels, the full plan allowance applies. Higher sustained activity can lower the allowance until earlier attempts leave the 7-day window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Repository YAML (base), Organization UI (inherited)

Review profile: CHILL

Plan: Pro Plus

Run ID: c0988814-c967-4aa6-a5c9-9b77fd159d2b

📥 Commits

Reviewing files that changed from the base of the PR and between 1281e32 and 2bc373a.

📒 Files selected for processing (4)
  • agents/pr-creation-agent/__tests__/unit/route-pr-template.test.js
  • agents/pr-creation-agent/jest.config.js
  • agents/pr-creation-agent/package.json
  • agents/pr-creation-agent/skills/validate-and-apply-labels.js

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

github-actionsBot commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

⚠️ A merged PR reached develop without passing the template content guardrail.

Missing required section(s): Changelog

This is a post-merge backstop for admin bypasses. Please review branch protection for develop.

@github-actions

github-actionsBot commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

⏱️ Aging and SLA annotation

  • Age: 0 day(s)
  • SLA state: Within SLA
  • Thresholds: warn at 7 days, breach at 14 days
  • Last updated: 2026-08-18T13:42:51.112Z

Maintained by project-meta-sync workflow.

@github-actionsgithub-actionsBot added status:needs-review Awaiting code review type:feature Feature or enhancement priority:normal Default priority area:documentation Docs & guides area:tests Test suites & harnesses lang:js JavaScript/TypeScript lang:md Markdown content/docs lang:json JSON config/content type:chore Chore / small hygiene change meta:needs-changelog Requires a changelog entry before merge labels Aug 18, 2026
@github-actions

github-actionsBot commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

🔍 Reviewer Summary for PR #2008

CI Status:success
Files changed: 3
Risk Distribution: 0 critical, 1 high, 1 medium, 1 low

Recommendations

  • Ready to proceed pending human review

@ashleyshaw
ashleyshawforce-pushed the feat/pr-route-template-skill branch from ae839c9 to f93ed21CompareAugust 18, 2026 15:31
@github-actionsgithub-actionsBot removed the type:chore Chore / small hygiene change label Aug 18, 2026
ashleyshaw pushed a commit that referenced this pull request Aug 18, 2026
Add comprehensive continuation prompt with full context:
- ⚠️ Production-ready status (all 88 tests passing)
- ⚠️ Merge conflict workaround for PR #1984 (use PR #1998)
- Complete Phase 2 roadmap (8 weeks, detailed)
- Exact implementation details for CLI commands
- Success criteria and verification checklist
- Related PRs status (#2008, #2009, #2023)
Version 2.0: Includes full merge status and workaround strategy.
Ready for next session to resume Phase 2 implementation.
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
@ashleyshaw
ashleyshawforce-pushed the feat/pr-route-template-skill branch 2 times, most recently from 9218721 to 6d017a7CompareAugust 18, 2026 22:28
@github-actions

Copy link
Copy Markdown
Contributor

❌ Branch Name Validation Failed

The branch name feat/pr-route-template-skill does not follow the LightSpeed branching strategy.

Required Format

{type}/{scope}-{short-title}
  • type: one of the allowed prefixes (lowercase)
  • scope: lowercase, hyphens only (no underscores or uppercase)
  • title: lowercase, hyphens only (no underscores or uppercase)

Allowed Branch Types

feat, fix, hotfix, release, refactor, chore, docs, test, perf, ci, build, deps, security, revert, research, design, a11y, ux, i18n, ops, proto, ds, api, schema, telemetry, content, seo, config, migrate, qa, uat, audit, codex

Valid Examples

  • feat/branch-naming-enforcement
  • fix/validation-script-bug
  • chore/update-dependencies
  • docs/branching-strategy-guide
  • hotfix/critical-security-patch

Invalid Examples

  • claude/my-branch (type "claude" not allowed)
  • Feature/MyBranch (uppercase not allowed)
  • fix-bug (missing type prefix)
  • feat/my_feature (underscores not allowed)
  • feat/MyFeature (uppercase not allowed)

Solution

Rename your branch to follow the pattern and update the PR.

For more information, see docs/BRANCHING_STRATEGY.md.

Test Userand others added 2 commits August 19, 2026 00:31
…entation)
Complete implementation of PR template routing skill for PR Creation Agent Phase 3.
- **route-pr-template.js** (~190 LOC): Routes PRs to templates based on branch type, loads YAML routing config, extracts metadata
- **route-pr-template.test.js**: 23 tests, 100% passing, 97%+ code coverage
- **Security**: Safe YAML parsing with DEFAULT_SAFE_SCHEMA
- **Integration**: Works with Skill 1 output (branchType), feeds Skill 3 (template metadata)
- Identifies sections from template content
- Detects required sections: 'Linked issues', 'Changelog', 'Checklist (Global DoD / PR)'
- Extracts frontmatter and content statistics
- Marks templates complete only when all required sections present
- 23 unit tests covering input validation, config loading, routing, file reading, metadata extraction, error handling
- 97.05% statement coverage, 94.44% branch coverage, 100% function coverage
- All 25+ documented branch types tested
- Error scenarios validated
- Phase 3: 2/6 skills complete (33%)
- Skill 1 (validate-branch-name): ✅ Complete (104 LOC, 39 tests)
- Skill 2 (route-pr-template): ✅ Complete (190 LOC, 23 tests)
- Skills 3-6: Ready for implementation
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
@ashleyshaw
ashleyshawforce-pushed the feat/pr-route-template-skill branch from 6d017a7 to 2bc373aCompareAugust 18, 2026 22:31
@ashleyshaw
ashleyshaw merged commit 07b32a5 into developAug 18, 2026
11 of 28 checks passed
@ashleyshaw
ashleyshaw deleted the feat/pr-route-template-skill branch August 18, 2026 22:35
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:documentationDocs & guidesarea:testsTest suites & harnesseslang:jsJavaScript/TypeScriptlang:jsonJSON config/contentlang:mdMarkdown content/docsmeta:needs-changelogRequires a changelog entry before mergepriority:normalDefault prioritystatus:needs-reviewAwaiting code reviewtype:featureFeature or enhancement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

@ashleyshaw