5c: report the depth cause from the guards, and make the publish converge
CI / gate (push) Successful in 7m12s
CI / publish (push) Has been skipped

This commit is contained in:
2026-09-03 21:19:01 +02:00
parent d9056973a1
commit 0dfcc0f9ca
19 changed files with 191 additions and 105 deletions
+5 -2
View File
@@ -498,8 +498,11 @@ Under **3 — `markdownToAdf` (`0.1.0`)**:
its own text: an attribute value past 500 levels was `unsupported-node-shape` on parse and
`not-an-adf-document` on emit, the document guard counting the `attrs` object as a level the
parser does not, so a value at exactly 500 parsed into a document the emitter then refused.
The guard now holds each attribute value to 500 of its own and runs a second time unbounded,
which parts depth from shape, and both directions answer with `unsupported-nesting-depth`.
Depth left the shape predicates on both sides: `isJsonValue` structural and `overNested`
beside it, `adfDocumentFault` returning the code with the message and `attributeValue` the
reason it refused, so both directions answer with `unsupported-nesting-depth` naming the
attribute, and `isAdfDocument` calls a deep document a document as it always did a deep
block.
`engines.node` gets its one-line proof too — the built entrypoint imported and round-tripped
under a pinned Node 18 image, which cannot run the suite that type stripping wants 22+ for,
but proves exactly what the field claims. Beside it, the emitted `.d.ts` typechecked from a