diff --git a/src/shared/utils/autoSeed.ts b/src/shared/utils/autoSeed.ts index 3e03548..77b7e06 100644 --- a/src/shared/utils/autoSeed.ts +++ b/src/shared/utils/autoSeed.ts @@ -8,18 +8,26 @@ * when explicitly enabled via the env var `FESTIPOD_AUTO_SEED` (= "1"). * * Same compile-time plumbing as the shared-wallet password (sharedWallet.ts): - * `build.ts` `define`s the global from the env var for a static bundle. Absent - * env → global undefined → seed OFF. + * `build.ts` `define`s the global from the env var. Absent env → global + * undefined → seed OFF, which is the whole point: OFF needs no plumbing at all. * * RECOVERED FROM THE ng-eventually BRANCH, with two differences that branch does - * not have: - * - there is no `/festipod-config.json` here, so the flag arrives at BUILD time - * only; a dev server picks it up from the environment it was built with; - * - `fixtureSeedEnabled()` below is NOT enforced in `bootstrapWallet` on this - * branch. On ng-eventually it switches every route off, which stands down the - * @data scenarios that seed; adopting that here is a product decision, not a - * side effect of recovering this file. Until it is taken, only the AUTOMATIC - * seed is gated — an explicit `loadTestData()` still writes. + * not have. + * + * TURNING IT ON ONLY REACHES A BUILT BUNDLE. `bun run dev` and `bun run start` + * both serve from `src/` (`src/index.ts` imports `index.html`), so the `define` + * in `build.ts` never reaches them — only `dist-staging/`, which the @e2e harness + * builds, is affected. ng-eventually closes that gap with a + * `/festipod-config.json` route read by `frontend.tsx` before the app loads; + * recovering it here means making the app bootstrap async, which is not needed + * for the gate's purpose (stopping the dev seed from bloating a persistent + * wallet) and is therefore left out until someone actually wants to opt in. + * + * `fixtureSeedEnabled()` BELOW IS NOT ENFORCED in `bootstrapWallet` here. On + * ng-eventually it switches every route off, which stands down the @data + * scenarios that seed; adopting that is a product decision, not a side effect of + * recovering this file. Until it is taken, only the AUTOMATIC seed is gated — an + * explicit `loadTestData()` still writes. */ /**