Repository navigation
fix: name the trailer in the CC014 advice when the message has no blank line - #696
Conversation
…nk line The proposed fix puts a blank line before the trailer it adds. For a message with no blank line of its own, that blank line was the first added line, so the advice read: Disclose the tool with "".
|
No actionable comments were generated in the recent review. Walkthrough
Merge Risk:
|
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #696 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 15 15
Lines 2600 2600
Branches 508 508
=========================================
Hits 2600 2600 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Merging this PR will degrade performance by 24.32%2 warnings
Warning Please fix the performance issues or acknowledge them on CodSpeed. Performance Changes
Tip Investigate this regression by commenting Comparing Footnotes
|



Before: With
ai_attribution = "disclose", a commit message with no blank line in it (a single line, or a subject followed directly by the tool's mark) failed CC014 with empty advice.After: The advice names the trailer to add.
A message that already has a blank line was not affected and prints the same advice as before.
How: The proposed fix puts a blank line before the trailer it adds. When the message had no blank line of its own, that blank line was the first new line, and the advice quoted it.
_added_linesnow leaves blank lines out. One parametrized test covers both message shapes; it fails on main and passes here.Summary by CodeRabbit