docs: the comparison table claims 24 rules, the package defines 22 - #35
Conversation
The competitor table is where a reader checks the claim hardest, so an
inflated count there costs more than it gains. docs/rules.md carries 22
{ #ccNNN } anchors and ALL_RULES has 22 entries with a rule ID
(CC001-CC013, CC101-CC102, CC201-CC202, CC301-CC304, CC401).
The existing tests prove every rule is documented; none of them read a
sentence that counts them, which is why this survived. A new test does,
over every page outside docs/blog/posts (dated records, per AGENTS.md).
It fails on the old number.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018xYa7m3qup5wyN5MaXFgf6
✅ Deploy Preview for commit-check ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Team Run ID: 📒 Files selected for processing (2)
Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe Commit Check documentation changes its documented rule count from 24 to 22. A documentation test scans Markdown files outside ChangesRule Count Synchronization
Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk: ⚪ Minimal · up to This updates the documented rule count to 22 and adds coverage to keep future rule-count claims synchronized with the catalog. No current merge-blocking risk remains. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
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 |
What
docs/compare/tools.mdsells the engine as "One rule engine with 24 documented rules". The real number is 22.Counted both sides:
docs/rules.mdcarries 22{ #ccNNN }anchorscommit_check.rules_catalog.ALL_RULEShas 22 entries with a rule ID — CC001–CC013, CC101–CC102, CC201–CC202, CC301–CC304, CC401The competitor comparison table is the page where a reader checks a claim hardest, and the rules page it links to is one click away, so an inflated count there costs more than it gains.
Why the existing tests missed it
tests/docs_sync_test.pyalready proves a great deal: every rule has an anchor, a section heading, and a "What it does / Why is this bad? / Options" body; every pasted failure line names a rule the package actually prints; every pinnedrev:matches the release; every config default matches the runtime.What none of them do is read a sentence that counts the rules out loud. So this drifted silently.
This PR adds
test_prose_rule_counts_match_the_catalog, which scans every page for theN documented rulesshape and compares it tolen(ALL_RULES).docs/blog/posts/is skipped —AGENTS.mdis explicit that blog posts are dated records and must not be moved forward.Verified the guard actually guards: with the number restored to 24 the new test fails; with 22 it passes.
Verification
🤖 Generated with Claude Code
https://claude.ai/code/session_018xYa7m3qup5wyN5MaXFgf6
Generated by Claude Code
Summary by CodeRabbit
Documentation
Tests