Repository navigation
Pin pr_review.py's Markdown Reader Gaps as Known Limits - #3270
Conversation
The code-span, heading, and line readers in pr_review.py still differ from GitHub's renderer at a paragraph's container end, after an even backslash run, inside a link title, at a heading's indent, and at a non-newline line separator. No reviewer body has carried any of these shapes, so each stays a limit, noted in CodeSpans' docstring and pinned by a test, rather than growing a container model. Co-Authored-By: Claude Opus 5.5 <[email protected]>
The local review found the container test pinning a list-item setext underline that GitHub renders the same way, and a tab case whose cause is the column a tab starts at rather than the container. It also found the note silent on a top-level setext underline and on the heading and line-split limits. Each note now names what its tests pin. The heading and line-split limits are noted in unrecognized_in's docstring, and a link destination case joins the title case. Co-Authored-By: Claude Opus 5.5 <[email protected]>
The second local review found the line-split note naming two of the separators the readers split on, the heading test pointing at a note that named neither heading reader, and the tab case's stated cause being one its line does carry. The note now names QUOTED_CHAR's set and both readers, the test pins each separator, and the tab case is stated as the quote-marker gap it is. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configuration
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 |
|
A recorded local strict-review pass covers head |
There was a problem hiding this comment.
🟡 Changes recommended
Correct the unrecognized_in docstring to exclude \r from the listed line-separator exception.
1 open issue
What changed in this PR
This pull request documents known Markdown reader limitations and adds regression tests that pin the current behavior.
Changes:
- Documents
CodeSpanslimitations. - Documents line-splitting and heading-indent limitations.
- Adds tests covering the documented cases.
| File | Summary |
|---|---|
tests/test_pr_review.py |
Adds regression tests for documented behaviors. |
scripts/pr_review.py |
Documents known reader limitations; one wording correction is required regarding carriage returns. |
Review effort: Lite
QUOTED_CHAR names the carriage return too, and GitHub does end a line there, so the note names the separators besides it and the newline. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
A recorded local strict-review pass covers head |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #3270 +/- ##
========================================
Coverage 65.49% 65.49%
========================================
Files 17 17
Lines 10011 10011
========================================
Hits 6557 6557
Misses 3454 3454
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
… Main (#3272) ## Summary Promotes two pull requests from develop, both from this round. - #3270: `pr_review.py`'s Markdown readers record where they still differ from GitHub's renderer as known limits, with notes in the `CodeSpans` and `unrecognized_in` docstrings. Tests pin each case: a paragraph end read from its line alone, a top-level setext underline, a span after an even backslash run, a backtick in a link's destination or title, a heading's indent, and the `str.splitlines` separators GitHub does not split on. - #3271: the file-naming check's `AUDIT.md` bullet, `filenaming.scripts` assert, and docstring say that a name with a dot and none of the listed extensions is not judged. A selftest case pins each side of that boundary. Closes #3240 Closes #3265 Closes #3263 Closes #3260 Closes #3259 Closes #3268 🤖 Generated with [Claude Code](https://claude.com/claude-code)

Summary
The maintainer chose to close #3240's class as documented, pinned limits rather than build a container model. The same call covers the four small reader follow-ups #3265, #3263, #3260, and #3259, none of whose shapes any reviewer body has carried.
CodeSpans' docstring names where its reading differs from GitHub's: a paragraph end read from its line alone, a top-level setext underline, a backtick run after an even backslash run, and a backtick inside an inline link's destination or title.unrecognized_in's docstring names thestr.splitlinesseparators GitHub does not split on, and the indentMARKDOWN_HEADINGandHEADINGaccept before a heading.The notes are docstrings rather than
#comments, since the prose gate'scomment-addedrule refuses new comment lines.These issues close through the promotion pull request: #3240, #3265, #3263, #3260, #3259.
Local review
Three recorded
agent-skillpasses, with 6, 3, and 1 findings. The first two rounds were fixed. One finding stayed open once the two-round edit budget was spent. Copilot raised it as well, and it is now fixed in 11b893e, with a fourth recorded pass finding 0:introduced:scripts/pr_review.pyunrecognized_indocstring saysstr.splitlines"ends a line at each other separatorQUOTED_CHARnames".QUOTED_CHAR's class also names\r, which GitHub does end a line at, so "other" should say other than the newline and the carriage return. The test docstring already states it that way.🤖 Generated with Claude Code