Skip to content

Commit bef8aeb

Browse files
docs(runtime): bind the outside-fence rule to heading recognition
The scanner comment read as if section CONTENT were also recognized only outside fences; the invariant is that headings are — fenced lines are literal content of their enclosing section by design. Generated-by: Claude Code
1 parent 94e96e7 commit bef8aeb

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

packages/runtime/src/history-compact-summary-validation.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -131,8 +131,12 @@ function findTruncationDefect(
131131

132132
// One line scan holding a single interpretation of the document for both
133133
// checks: the mandated sections must appear in order, each with non-empty
134-
// content, and only OUTSIDE fenced code blocks — a degraded model quoting the
135-
// template inside a fence must not count as structure. Fences follow the
134+
// content. Section HEADINGS are recognized only OUTSIDE fenced code blocks —
135+
// a degraded model quoting the template inside a fence must not count as
136+
// structure — while fenced lines are literal content of their enclosing
137+
// section (preserved commands and errors are exactly what a checkpoint must
138+
// carry; only template placeholders and bare marker runs are excluded).
139+
// Fences follow the
136140
// Markdown closing rule: same character family AND a run at least as long as
137141
// the opener (a shorter run stays fenced content), tracked line-opening only
138142
// so a verbatim ``` inside a preserved error message stays content. The scan

0 commit comments

Comments
 (0)