refactor(dev): remove the minimal-registry escape hatch (#6163)

* refactor(dev): remove the minimal-registry escape hatch

`dev:minimal` existed because the tool registry was 71-82% of every workspace
route's module graph and aliasing it away was the only way to make dev bearable.
The metadata work removed that reason, so the hatch now buys almost nothing:

  before this stack   31.7s -> 20.0s cold  (-37%)
  after this stack    22.9s -> 20.7s cold  (-10%)

A 10% cold-compile win, on the run that happens once — restarts are ~4.2s either
way — is not worth what it costs. `tools/registry.minimal.ts` and
`blocks/registry-maps.minimal.ts` are 283 lines of hand-curated duplicates of the
real registries that **nothing keeps in sync** (no lint, no CI check, no test);
they are correct today only because someone remembered. And the mode is actively
misleading: it silently drops ~250 services and ~280 blocks, so anything
reproduced under it may not reproduce for real.

Removes both files, the `SIM_DEV_MINIMAL_REGISTRY` branch from `next.config.ts`
(including the whole `webpack()` hook, which existed only for this), and the
`dev:minimal` / `dev:full:minimal-registry` scripts.

Verified after removal: `tsc` clean, boundary + metadata + skills + monorepo
gates pass, and `next dev` starts and serves the canvas at 22.6s cold / HTTP 200.

* fix(setup): stop the wizard offering the removed minimal-registry mode

The setup wizard prompted for a dev server on machines under 16GB and
**defaulted** to `dev:full:minimal-registry` — a script this stack deletes.
Anyone running `bun run setup` on a low-RAM machine would have accepted the
default and hit "Script not found", which is exactly the contributor the mode
existed to help.

Repointed at `dev:full:capped`, which still exists and caps Node at 4GB without
dropping ~250 integrations — a strictly better answer to the same question.

The hints were also stale: they warned the full registry "can use 4-5GB+ on its
own", which was true when a dev server sat at 11.5GB. It now sits at ~4GB, so
they say that instead.

Missed by an earlier sweep because the pattern searched for `dev:minimal` and
`registry.minimal`, and this string is `dev:full:minimal-registry` — the two
halves reversed. Re-swept across every file type for all spellings: zero
references remain. Also audited every script value the wizard can return, so the
class of bug is checked, not just this instance.
This commit is contained in:
Waleed
2026-08-01 11:27:38 -07:00
committed by GitHub
parent e8894a8764
commit 03649e934c
6 changed files with 6 additions and 333 deletions
+6 -6
View File
@@ -163,17 +163,17 @@ export async function runDevMode(
message: `Low RAM detected (${detection.specs.hostMemGb}GB) — which dev server?`,
options: [
{
value: 'dev:full:minimal-registry',
label: 'Minimal block registry (recommended)',
hint: 'much lower memory — loads fewer integration blocks in dev',
value: 'dev:full:capped',
label: 'Capped heap (recommended)',
hint: 'caps Node at 4GB — every integration still available',
},
{
value: 'dev:full',
label: 'Full registry',
hint: 'every block available — can use 4-5GB+ on its own',
label: 'Uncapped',
hint: 'lets the dev server take what it needs (~4GB typical)',
},
],
initialValue: 'dev:full:minimal-registry',
initialValue: 'dev:full:capped',
})
}
return {