From 2b05ddce3cc9cc2de82884d1e27a4d3366ae7b3f Mon Sep 17 00:00:00 2001 From: Doxa Maps Date: Tue, 29 Sep 2026 03:53:42 +0000 Subject: [PATCH] check:packets-all asserts zone coverage only where a zone was generated gates:pre's check:packet-offline writes the four fixture packets into the same directory this gate reads, so after gates:pre that directory is never empty. A tree that had generated no zone then failed here on all 28 zones, and gates:post was red on every landing for nothing anyone could fix. Fixtures exercise the renderer, not a zone. With only fixtures present the coverage assertion now says it did not run, and the per-packet checks still run on the fixtures. One zone packet present and all 28 are required, as before: planted with laos alone, it fails on the other 27. --- internal/check-packets-all.mjs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/internal/check-packets-all.mjs b/internal/check-packets-all.mjs index 259904de4..73ada6cb5 100644 --- a/internal/check-packets-all.mjs +++ b/internal/check-packets-all.mjs @@ -88,7 +88,14 @@ if (!files.length) { const { buildLegendNodes, leafZones } = await import(pathToFileURL(resolve(REPO, 'plugin-designs/my-upg-100-list/data/legend-tree.js')).href) const zones = leafZones(buildLegendNodes(z, { records: null })).map((l) => l.id) const have = new Set(all.map((f) => f.replace(/\.html$/, ''))) - for (const id of zones) if (!have.has(id)) failures.push(`zone '${id}' has NO generated packet at all`) + // ★ COVERAGE IS ASSERTED WHERE ZONES WERE GENERATED. gates:pre's check:packet-offline writes the four + // fixture-* packets into this directory, so after gates:pre it is never empty, and a tree that had + // generated no zone failed here on all 28: gates:post was red on every landing, for nothing anyone + // could fix. Fixtures exercise the renderer, not a zone. One zone packet here and all 28 are required. + if (!zones.some((id) => have.has(id))) { + console.log(`PACKETS-ALL (headless): coverage not asserted — no zone packet here, only ${all.length} fixture/variant packet(s)`) + console.log(' ONLY= node library/scripts/posters/packet.mjs generates one; then every zone is required.') + } else for (const id of zones) if (!have.has(id)) failures.push(`zone '${id}' has NO generated packet at all`) } // 2. PER PACKET: a non-empty map page and N > 0 groups. The map page is the FIRST sheet; without // the lifted poster it holds only the kicker/title/subtitle, so "contains an