Skip to content

fix: Resolve infrastructure bugs #1928, #1930, #1938 - #2007

Closed
ashleyshaw wants to merge 6 commits into
developfrom
feat/adr-agent-phase-1b-clean
Closed

fix: Resolve infrastructure bugs #1928, #1930, #1938#2007
ashleyshaw wants to merge 6 commits into
developfrom
feat/adr-agent-phase-1b-clean

Conversation

@ashleyshaw

@ashleyshawashleyshaw commented Aug 18, 2026

Copy link
Copy Markdown
Member

Summary

This PR resolves three critical infrastructure bugs affecting CI/CD validation and branch naming enforcement.

  • Fixes gitleaks false positive in OPENSPEC_TEMPLATE.md example code
  • Fixes PR template validator missing 'Global DoD Checklist' detection
  • Fixes branch name validator permitting invalid characters (uppercase, dots, underscores)

Linked issues

Fixes#1928
Fixes#1930
Fixes#1938

Changes

Bug #1928 - Gitleaks False Positive

  • Added gitleaks ignore comments around example curl command in OPENSPEC_TEMPLATE.md
  • Prevents security scanner from flagging valid example bearer tokens

Bug #1930 - PR Template Validator

  • Fixed regex in sectionBody() to match all heading levels (###) not just ##
  • Pattern changed from /^##\s+.+$/m to /^#+\s+.+$/m
  • Now correctly detects 'Changelog' and 'Global DoD Checklist' sections

Bug #1938 - Branch Name Validator

  • Enforced strict kebab-case validation (lowercase, hyphens only)
  • Changed regex from [a-zA-Z0-9._-]+ to [a-z0-9-]+
  • Updated test cases to reflect proper validation rules
  • Complies with CLAUDE.md requirement for lowercase, kebab-case branch names

Test Plan

  • All existing tests pass with updated branch validation rules
  • PR template validator correctly detects all required sections
  • Gitleaks ignores example code in OPENSPEC_TEMPLATE.md
  • Branch validation rejects uppercase letters, dots, and underscores

Changelog

  • Fixed gitleaks false positive in OPENSPEC_TEMPLATE.md
  • Fixed PR template validator false negatives on required sections
  • Fixed branch name validator to enforce strict kebab-case

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)

🤖 Generated with Claude Code

Test Userand others added 6 commits August 18, 2026 15:14
Phase 1B: Templates & Validation System
- 4 ADR templates (standard, lightweight, security, infrastructure)
- Template loader with schema validation
- 6 validators (enforcing naming, date formats, frontmatter, structure, etc.)
- Validation orchestrator for multi-step checks
Phase 1C: ADR Discovery Skill
- Discovery skill for finding ADRs in repositories
- Filters by file patterns and frontmatter criteria
- Integration with Phase 1A configuration system
All 88 tests passing. Copilot code quality fixes applied.
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
The documentation pattern check was coming after the feature pattern check,
causing titles like 'docs: Add README' to match the feature pattern first
(due to 'add') instead of the documentation pattern.
Changed: Move documentation check before feature check and remove 'add'
from feature pattern to avoid false positives.
Fixes failing test: should detect type:documentation from issue titles
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
- Remove backup file (adr-template-loader.js.bak) to reduce noise
- Fix enforceValidReferences() to handle both numeric and date-based ADR IDs
- Add fallback for empty slugs in generateFilename() to prevent invalid filenames
- Add complete frontmatter to adr-discovery.md with standard metadata fields
Addresses comments:
- Line 85 (enforceValidReferences pattern ordering)
- Line 133 (generateFilename empty slug fallback)
- adr-discovery.md frontmatter completion
- .bak file removal
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
Fixed 40+ markdown linting violations:
- Removed trailing punctuation from headings
- Added missing blank lines around headings, lists, and code blocks
- Ensured consistent formatting with markdownlint-cli2 standards
Files fixed:
- .github/operations/MILESTONE_ALLOCATION_ANNOUNCEMENT.md
- .github/operations/MILESTONE_ALLOCATION_MONITORING.md
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
- Fixed unresolved merge conflict in CHANGELOG.md from PR #1989
- Restored 5 recent entries that were inadvertently removed:
* PR #2001: PR Creation Agent Phase 3 — Skills 5 & 6
* PR #1999: CI Validators Infrastructure — validate:frontmatter:changed script
* PR #1994: Project Maintenance Agent — Phase 1 & 2 Documentation
* PR #1993: Project documentation scripts security/logic/testing fixes
* PR #1995: Phase 5A agentic release team training guide
- Restored ADR Agent Phase 1B & 1C implementation entry
- Restored Reports & Projects Restructuring Phase 4 entry
- Removed duplicate GitHub Actions v7 upgrade entry
- All recent PRs (Aug 12-18) now accurately reflected
**#1928 - Gitleaks false positive in OPENSPEC_TEMPLATE.md**
- Added gitleaks ignore comments around example curl command
- Prevents security scanner from flagging valid example bearer tokens
**#1930 - PR template validator false negatives**
- Fixed regex in sectionBody() to match any heading level (#, ##, ###)
- Changed pattern from /^##\s+.+$/m to /^#+\s+.+$/m
- Now correctly detects 'Changelog' and 'Global DoD Checklist' sections
**#1938 - Branch name validator false negative**
- Enforced strict kebab-case (lowercase, hyphens only)
- Changed regex from [a-zA-Z0-9._-]+ to [a-z0-9-]+
- Updated tests to reject uppercase letters, dots, and underscores
- Complies with CLAUDE.md requirement for lowercase, kebab-case branch names
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
@coderabbitai

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:41 minutes

Limit details: You’ve used all 1 included review currently available under your plan.

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 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 configuration

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

Review profile: CHILL

Plan: Pro Plus

Run ID: 11831001-bf9c-4fbb-b430-5b3434e147ba

📥 Commits

Reviewing files that changed from the base of the PR and between ccc8577 and cd19879.

📒 Files selected for processing (19)
  • .github/operations/MILESTONE_ALLOCATION_ANNOUNCEMENT.md
  • .github/operations/MILESTONE_ALLOCATION_MONITORING.md
  • .github/projects/_templates/OPENSPEC_TEMPLATE.md
  • CHANGELOG.md
  • agents/adr-generator/SKILL.md
  • agents/adr-generator/skills/adr-discovery.js
  • agents/adr-generator/skills/adr-discovery.md
  • agents/adr-generator/skills/adr-validation-orchestrator.js
  • agents/adr-generator/templates/infrastructure.md
  • agents/adr-generator/templates/lightweight.md
  • agents/adr-generator/templates/security.md
  • agents/adr-generator/templates/standard.md
  • agents/adr-generator/tests/discovery.test.js
  • agents/adr-generator/tests/template-loader.test.js
  • scripts/automation/__tests__/auto-update-all.test.js
  • scripts/automation/auto-update-all.js
  • scripts/validation/__tests__/validate-branch-name.test.js
  • scripts/validation/template-helpers.cjs
  • scripts/validation/validate-branch-name.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.

@ashleyshaw
ashleyshaw enabled auto-merge (squash) August 18, 2026 13:34
@github-actions

github-actionsBot commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

✅ Template check passed after update. Thanks for fixing the PR description.

@github-actions

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:34:33.696Z

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:theme Theme & styles area:documentation Docs & guides area:tests Test suites & harnesses labels Aug 18, 2026
@github-actions

Copy link
Copy Markdown
Contributor

📄 README Validation

✅ All README checks passed.

CheckResult
✅ FrontmatterPassed
✅ StructurePassed

@github-actionsgithub-actionsBot added area:scripts Scripts & tooling lang:js JavaScript/TypeScript lang:md Markdown content/docs type:chore Chore / small hygiene change type:bug Bug or defect meta:needs-changelog Requires a changelog entry before merge labels Aug 18, 2026
@github-actions

Copy link
Copy Markdown
Contributor

🔍 Reviewer Summary for PR #2007

CI Status:success
Files changed: 19
Risk Distribution: 0 critical, 4 high, 4 medium, 11 low

Recommendations

  • ⚠️ Security-sensitive files modified (review carefully)

@ashleyshaw

Copy link
Copy Markdown
MemberAuthor

Closing in favor of a cleaner PR with only infrastructure bug fixes

auto-merge was automatically disabled August 18, 2026 13:42

Pull request was closed

@github-actionsgithub-actionsBot removed type:feature Feature or enhancement type:chore Chore / small hygiene change labels Aug 18, 2026
@ashleyshaw
ashleyshaw deleted the feat/adr-agent-phase-1b-clean branch August 18, 2026 14:04
ashleyshaw pushed a commit that referenced this pull request Aug 21, 2026
…-08-21)
Issue status review documenting:
- Closed#1930: PR template validator false negative (via #2007, #2010)
- Closed#2051: Frontmatter freshness CI issues (via #2180)
- Enhanced #2186: Template validation script false positives with DoR/DoD
- Enhanced #2147: Phase 1 validation tests with progress tracking
- Verified #2049: OpenSpec Labels Phase 2-3 epic (complete)
All high-priority issues now have complete Definition of Ready and Definition
of Done sections reflecting merged work into develop branch.
References: #2186, #1930, #2051, #2147, #2049
Related PRs: #2193, #2180, #2183, #2173, #2153, #2210, #2221
mergifyBot added a commit that referenced this pull request Aug 21, 2026
* docs: Issue status review — DoR/DoD completion audit (2026-08-21)
- Closed#1930: PR template validator false negative (merged via #2007, #2010)
- Closed#2051: Frontmatter freshness CI issues (merged via #2180)
- Updated #2186: Template validation script false positives with DoR/DoD
- Updated #2147: Phase 1 validation tests progress tracking with DoR/DoD framework
- Verified #2049: OpenSpec Labels Phase 2-3 epic (complete, merged)
All high-priority issues now have complete Definition of Ready and Definition of Done sections reflecting merged work into develop branch.
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018MoY39EXD6tnbbjs3JVUqT
* revert: remove misplaced issue status review from root
---------
Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:documentationDocs & guidesarea:scriptsScripts & toolingarea:testsTest suites & harnessesarea:themeTheme & styleslang:jsJavaScript/TypeScriptlang:mdMarkdown content/docsmeta:needs-changelogRequires a changelog entry before mergepriority:normalDefault prioritystatus:needs-reviewAwaiting code reviewtype:bugBug or defect

Projects

None yet

1 participant

@ashleyshaw