Checkpoint: current Lumen state
Some checks failed
ci / check (push) Has been cancelled

This commit is contained in:
Lumen Stage1 2026-09-23 18:58:21 -05:00
commit fcc18ddcc8
96 changed files with 8074 additions and 214 deletions

View file

@ -164,9 +164,9 @@ Hard rules carried into implementation `ARCHITECTURE-DESIGN.md:928`: no feature
| Database | Stores | Keys / contents | Lifecycle |
|---|---|---|---|
| `lumen-system` | `meta` (single object store) | Active slot pointer (`A`/`B`), `activeEdition`, `activePackageVersion`, verification record (what/when/which, fingerprint, manifestSha256), `appVersionAtActivation`, staging progress (`floor`, per-file), `readbackPending`, clock skew cache pointer | Single source of truth for readiness; rewritten atomically on activation (P2) |
| `lumen-slot-a` | `files`, `assets` | `files`: section docs keyed by section id (`emergency`/`schedule`/`map`/`info`/`assets.json`); `assets`: Blobs keyed by asset id (`map-base-*`, icons) | Inactive slot is staging target; active slot is truth; GC per §13 |
| `lumen-slot-b` | `files`, `assets` | Same as above | Same |
| `lumen-system` | `meta` (single object store) | Active slot pointer (`A`/`B`), `activeEdition`, `activePackageVersion`, verification record (what/when/which, fingerprint, manifestSha256), `appVersionAtActivation`, `readbackPending`, clock skew cache pointer | Single source of truth for active/readback metadata; rewritten atomically on activation (P2); no per-file staging progress |
| `lumen-slot-a` | `files`, `assets`, `staging` | `files`: section docs keyed by section id (`emergency`/`schedule`/`map`/`info`/`assets.json`); `assets`: Blobs keyed by asset id (`map-base-*`, icons); `staging`: authoritative slot-local journal | Inactive slot is staging target; file/asset + journal commit in one transaction; active slot is truth; GC per §13 |
| `lumen-slot-b` | `files`, `assets`, `staging` | Same as above | Same |
| `lumen-user` | `favorites` (by stable event id), `prefs`, `diag` (scrubbed ring buffer) | Favorites `id → { addedAt }`; `prefs` (theme, clock, `displayMode` flags); `diag` (quarantined versions, recent errors) | Never GC'd by dataset logic (B-6); own idempotent migrations (package schema separate, `SPIKE-04:210`) |
| `lumen-shell-v<build>` (Cache) | Cache Storage | Precached shell (hashed JS/CSS/icons, `index.html`, `fallback.html`) | Versioned per build; old caches deleted on SW `activate` |
| (localStorage) | Guarded flags only | Coach dismissed, etc. — `try/catch` | Non-load-bearing |
@ -179,7 +179,7 @@ Invariant: at every observable moment `lumen-system.meta.activeSlot` points at e
- Two dataset slot databases; updates stage exclusively into the **inactive** slot (`ARCHITECTURE-DESIGN.md:659`).
- Per-file staging is one short txn: `bytes + progress record` together (P1, F-1 `SPIKE-02:89`); no txn spans non-IDB await.
- Staging progress persisted per file; resume keyed on committed progress; staging older than 7 days discarded (`ARCHITECTURE-DESIGN.md:669`).
- Staging progress is authoritative in the target slot's `staging` journal; resume is keyed on committed slot-local progress; staging older than 7 days is discarded (`ARCHITECTURE-DESIGN.md:669`).
- Beginning a new staging run wipes the inactive slot — rollback depth is exactly **1** (three-slot rejected for footprint, `SPIKE-02:100` F-4). Invariant holds (valid dataset always active); only undo depth is bounded.
- Downloads run in **page context**, never SW (C-21, P8).