fix: skip parsing clang-tidy diagnostic rationale#237
Conversation
Specifically when the rationale line has added context in square brackets. This includes a test based on the actual bug reported in cpp-linter/cpp-linter-action#389. Corresponds to cpp-linter/cpp-linter#176
WalkthroughThe PR modifies clang-tidy diagnostic parsing to distinguish real diagnostics from false-positive brackets by introducing a validation guard, adjusts path normalization logic to be conditional on compilation database presence and findings, and adds a test case to verify the new diagnostic detection behavior. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: Organization UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (2)
🧰 Additional context used🧠 Learnings (5)📓 Common learnings📚 Learning: 2024-09-29T18:00:02.286ZApplied to files:
📚 Learning: 2025-11-04T06:50:10.870ZApplied to files:
📚 Learning: 2024-11-23T06:20:11.698ZApplied to files:
📚 Learning: 2025-01-21T09:56:32.771ZApplied to files:
🧬 Code graph analysis (1)cpp-linter/src/clang_tools/clang_tidy.rs (1)
🔇 Additional comments (5)
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 |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #237 +/- ##
==========================================
+ Coverage 96.93% 96.98% +0.05%
==========================================
Files 14 14
Lines 3033 3085 +52
==========================================
+ Hits 2940 2992 +52
Misses 93 93 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Specifically when the rationale line has added context in square brackets.
This includes a test based on the actual bug reported in cpp-linter/cpp-linter-action#389.
Corresponds to cpp-linter/cpp-linter#176
Summary by CodeRabbit
Bug Fixes
Tests
Chores
✏️ Tip: You can customize this high-level summary in your review settings.