From afb998f17bf762ce12323c1822bf205234bae8a9 Mon Sep 17 00:00:00 2001 From: doxa-maps-88655c70 <88627970+doxa-maps-88655c70@users.noreply.github.com> Date: Tue, 22 Sep 2026 14:34:58 +0000 Subject: [PATCH] Archive the repo-root staging page; the studio is the only entry now MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit There were THREE staging surfaces, not two. The repo-root index.html was Vite's default dev entry, and its title was the line that kept reappearing in front of the Driver: "doxa-maps · Embeddable JAMstack Maps · staging", above a bundle strip that loaded each chosen map into the page itself. It is archived with its internal/staging.js, not deleted, and git recorded both as renames so history follows. Archiving is safe because it was never a build input: rollupOptions.input is built from per-bundle JS entries, and the root HTML is referenced only on the dev branch. It was also already unreachable — the dev plugin intercepts /, /index.html, a query-string root and /__gallery, all measured returning the studio with no staging title before the move, and measured again after. What remained was a file that would resurface the moment the middleware changed. The settled-tree leaf floor drops from 50 to 40 because the architecture changed, not because the tree got sicker. That floor was set when the build also emitted a chooser page per bundle; those 19 pages are deliberately gone, which takes a correct tree from 63 leaves to 44. Left at 50 the gate would fail on every correct build, and the cheapest way to make it green again would be to restore the choosers — so a stale floor does not protect the tree, it defends the old architecture. The floor still catches the partial-wipe it was built for, and the load-bearing assertion is now that every embed.iframe target resolves: 43 checked, 0 missing. --- .../staging-surface-2026-09-22/index.html | 0 .../staging-surface-2026-09-22}/staging.js | 0 internal/settled-tree-gate.mjs | 23 ++++++++++++++++++- 3 files changed, 22 insertions(+), 1 deletion(-) rename index.html => _archive/staging-surface-2026-09-22/index.html (100%) rename {internal => _archive/staging-surface-2026-09-22}/staging.js (100%) diff --git a/index.html b/_archive/staging-surface-2026-09-22/index.html similarity index 100% rename from index.html rename to _archive/staging-surface-2026-09-22/index.html diff --git a/internal/staging.js b/_archive/staging-surface-2026-09-22/staging.js similarity index 100% rename from internal/staging.js rename to _archive/staging-surface-2026-09-22/staging.js diff --git a/internal/settled-tree-gate.mjs b/internal/settled-tree-gate.mjs index 01f88e877..357461f5b 100644 --- a/internal/settled-tree-gate.mjs +++ b/internal/settled-tree-gate.mjs @@ -44,7 +44,28 @@ import { execSync } from 'node:child_process' const TREE = process.env.TREE || 'public/doxa-maps' const QUIET_SECONDS = Number(process.env.QUIET_SECONDS || 45) const MIN_DIRS = Number(process.env.MIN_DIRS || 17) -const MIN_LEAVES = Number(process.env.MIN_LEAVES || 50) +// ★ RECALIBRATED 2026-09-22 from 50 to 40 — the ARCHITECTURE changed, not the health of the tree. +// The old floor was set when generate-tree.mjs also emitted a /index.html CHOOSER page for +// every bundle. Those 19 pages were removed deliberately (they returned HTTP 200, mounted NOTHING, +// were referenced by the manifest ZERO times, and their stylesheet was literally named +// "staging-forge" — they are the duplicate staging surface the Driver asked to archive). Removing +// them legitimately drops the recursive index.html count from 63 to 44. +// +// ★ WHY THIS EDIT MATTERS MORE THAN THE NUMBER: left at 50, a CORRECT tree fails this gate forever, +// and the cheapest way to make it green again is to restore the choosers — i.e. the stale floor +// would quietly pressure the next agent into undoing the change it was blocking. A floor that +// encodes a removed artifact does not protect the tree; it defends the old architecture. +// +// 40 keeps the original PURPOSE intact. The floor exists because a per-bundle `BUNDLE=x vite build` +// silently deletes every OTHER bundle's leaf (see the note at signal 4) — a partial-wipe leaves far +// fewer than 40. The expected healthy count is now 44: 1 root + 28 profile leaves + 15 instance +// leaves. Anything materially below that is the wipe this gate was built to catch. +// +// THE LOAD-BEARING CHECK IS NO LONGER THIS COUNT. What actually must not break is that every +// embed.iframe target in manifest.json still resolves — that is deployment method 1, one of only two +// of the five that are proven. Verified 2026-09-22: 43 iframe targets checked, 0 missing. Prefer +// check:embed-targets for that assertion; this floor is only a coarse wipe detector. +const MIN_LEAVES = Number(process.env.MIN_LEAVES || 40) if (!existsSync(TREE)) { console.error('SETTLED-TREE: FAIL — tree does not exist: ' + TREE + ' (a build may be mid-clean)')