fix(anatomy): R5.4 records bounded in total, CHANGELOG tables projected before they are joined

This commit is contained in:
bchanot committed 2026-10-23 14:58:40 +02:00
1 parent 777c8000b8
commit 5880dfa959
9 files changed
+258 -6

No files matched your search

+4 -2
View File
@@ -3203,7 +3203,8 @@ pass the guard unchanged.
|---|---|---|
| authored text outside the allowlist: Markdown Prettier rewrites (`*x*`, `_x`, `x_**a**`, `**a****b**`, `Voir_https://…`, `a b`, a non-ASCII space, a tab, a line break in a list item, `` `` ``, `a\|b`, `[a](<b>)`, `[[ a ]]`, `&#42;`…), the constructs refused whole (links, HTML tags, autolinks, character references) and any character outside the admitted set (pictographs, symbols, combining marks without the Alphabetic property; an alphabetic mark such as U+0345 is a letter and Prettier aligns it alike) | written, then rewritten by Prettier (escapes, `_emphasis_`, collapsed spaces, indented continuation lines, normalised links; a row with an extra cell), or kept | refused (`UnsupportedMarkdown`), even where Prettier would have kept the text |
| a pictograph in a table cell (an emoji, and ©, ®, ™, ✓, ★, ⚠ and the other characters `text::is_emoji_candidate` lists) | measured with Prettier's tables | refused (`UnsupportedWidth`, R5.2): the set is wider than the emoji, the refusal stays loud |
| an aligned report table past 32 Mi display columns in all (rows × padded row width; the equine CHANGELOG's widest table is about 0.5 MB): one long authored cell pads every row of its level, so an 80 KB rationale over 14,000 records asked for 1 GB (security gate R5.4 round 6) | Prettier aligned it (the same amplification) | refused before any row is built (`Guard`, test `an_aligned_table_past_the_bound_is_refused_before_it_is_built`), import report included |
| an aligned report table past 32 Mi display columns in all (rows × padded row width; the equine CHANGELOG's widest table is about 0.5 MB): one long authored cell pads every row of its level, so an 80 KB rationale over 14,000 records asked for 1 GB (security gate R5.4 round 6) | Prettier aligned it (the same amplification) | refused (`Guard`): the CHANGELOG's tables are projected from their cells (bytes bound the display width) before the raw table is joined (test `a_changelog_whose_alignment_would_explode_is_refused_before_it_is_built`, through the pipeline), every other table in the aligner before any padded row is built (test `an_aligned_table_past_the_bound_is_refused_before_it_is_built`), import report included |
| records weighing more than 16 Mi units in all (`records::record_weight`: 64 per JSON value plus one per string byte of the values and of the change's texts, which each record clones; the equine records weigh 1,084,422): a rename or a remove records the whole item, so 400 renames of a 5,000-child item asked for 4.3 GB, and an 80 KB rationale repeated over 14,000 records for 1.1 GB of raw rows (security gate R5.4 round 7) | recorded (the same copies) | refused at the op that passes the bound, before the next op records anything (test `the_records_cannot_outgrow_their_bound`); the raw report rows, built from the records, are bounded with them |
| an id an `add` writes (the item's, and those nested in its `children` or `categories`) or a `rename` id that is not a stable id (a region code for a region), or a field segment outside `[A-Za-z0-9_-]` (a control character, NUL included, a backtick, a `]`, a space, a non-ASCII letter) | accepted when a later op removed or renamed the item: the raw id stayed in the records and reached the reports' code spans (a line break there forged a section, security gate R5.4 round 2) | refused at the op, the check the final document applies anyway (test `ids_and_field_segments_that_could_forge_report_structure_are_refused`) |
| a label, id or path holding a code point XML 1.0 refuses, or a carriage return, in a review drawing | written (a non-well-formed file; a raw CR read back as a line feed) | refused: the drawing is not written |
@@ -3240,7 +3241,8 @@ ruled and frozen in the sweep, so a combination of admitted characters no probe
differ; the comparison of the application's drawings accepts
exactly the trigger-name rule, byte for byte; the frozen
`horse.svg` is read, never regenerated, so a future change of the drawing needs its own
decision; the review drawings are bounded only through the document's 200,000 values (two drawings
decision; one op still records up to about three copies of an item under the 200,000-value bound
before the records bound is checked (tens of MB at most); the review drawings are bounded only through the document's 200,000 values (two drawings
of about 137 KB per view, about 2 GB at the bound, an estimate of the security gate R5.4 round 6,
not measured), and the allowlist admits the invisible Hangul fillers (U+3164, U+115F, U+1160,
U+FFA0, letters Prettier keeps, no structure); the residual risks of §11.13 stand.