Repository navigation
fix(writing): judge the TL;DR first block, allow inline code - #260
Conversation
The TL;DR check tested only the first character of the summary, so it rejected a sentence opening with inline code and accepted blocks that are not prose: lists, thematic breaks, link and footnote definitions, setext headings and tables without a leading pipe. The summary must now open with a paragraph that starts with a word, emphasis, a link or a closed code span of one or two backticks. Line 1 is also tested as a list item, break or definition, line 2 as a table delimiter row, and the paragraph lines for a setext underline, following CommonMark 0.31.2 and cmark-gfm. tldr-gates.test.sh gains TLDR_GATES_CASES to run chosen cases: its full matrix outlasts a ten-minute foreground run, so the new cases could not leave test receipts otherwise. Rejected: a real Markdown parser (a runtime the hooks lack on every host) and counting table columns (a delimiter-shaped second line is no summary either). Fixes #257
A mistyped TLDR_GATES_CASES label selected no all-gates case, so the suite passed on its library checks alone: no_such_case reported 10 passed, 0 failed. The suite now records each case it runs and fails once for every requested label that ran none; the no_such_case receipt on this tree is that intended failure. The linear-pattern comment in concise-writing.sh now names unbounded whitespace runs, since the delimiter-row pattern lets a bounded indent overlap.
concise-writing.test.sh covers the new summary rules and their linear-time bounds, but CI ran only the stop-gate and PR-review suites, so the new Perl patterns were exercised on macOS alone. The writing-ownership job now runs the unit suite on ubuntu-latest after stop-gate.test.sh. Rejected: running the full tldr-gates matrix in CI, which takes over ten minutes against the job's 15-minute timeout.
ARCHITECTURE.md described the writing-ownership job as the ownership check plus the reference-delivery tests. Since f7863e0 the job also runs .agents/lib/concise-writing.test.sh, so the map names it and its purpose.
|
Note Currently processing new changes in this PR. This may take a few minutes, please wait... ⚙️ Run configuration
📒 Files selected for processing: 6
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 |
TL;DRThe PR author must acknowledge the current diff and description before requesting review. Author review acknowledgmentAwaiting the PR author's acknowledgment. @DorianZheng: read the current diff and description, then check: Apply boxlite-writing. Does How it works explain the diff's mechanism or rationale? Use the form best suited to the change. Check drafts too, and repeat this review Unacknowledged PRs are converted to draft. After this check passes, click Ready for review when you want reviews. |
The research gate (#254), the auditor-control fix (#250), the verdict check exec (#258) and the TL;DR first-block rule (#260) all shipped under 0.1.30. The commit/push gate detects a stale session plugin only by version, so loaded 0.1.30 auditors would reject the newer tasks instead of asking for a reload. All seven version fields move to 0.1.31, and CONTRIBUTING gains a rollout note: research is reviewed before the first edit, code from any 0.1.30 build gets that review before its next commit or push, TL;DR summaries must open with a paragraph, and sessions must reload. Rejected: keeping 0.1.30, whose equal versions skip the reload check. Fixes #256
TL;DR
A TL;DR summary may now open with inline code, and a list, break, definition, setext heading or table no longer passes as the summary.
Design doc: #257
Documentation: ARCHITECTURE.md, Mandatory summary and the CI wiring note
How it works
concise-writing.shtested only the first character of the summary. It now judges the first block, following CommonMark 0.31.2 and cmark-gfm:## TL;DR, start one plain sentence with a word or inline code".TLDR_GATES_CASESruns chosentldr-gatescases within a ten-minute foreground run, and CI runs the new unit suite on Linux.Verification
make test:plugin TEST_FILTER=concise-writing: 56 forms and 200,000-character linesTLDR_GATES_CASES=code_start,list_start,setext_start make test:plugin TEST_FILTER=session/tldr-gates.testtldr-gatesmatrix, before the filter commits