clone

a deno framework for local-first web apps that open instantly, work offline and sync when users choose

feat/141-demo-review-fixes
lofi / docs / spikes / opfs-device / evidence / 2026-07-15.md
2026-07-15.md 3.7K rendered
1# OPFS desktop preflight and device evidence — 2026-07-1523Issue: [#4](https://github.com/FelineStateMachine/lofi/issues/4)\4Exact stack: Jazz 2.0.0-alpha.53, Astro 7.0.9, Preact 10.29.7, Deno 2.9.0\5Desktop preflight: macOS 26.5.1, Headless Chrome 150.0.0.067## Enforced behavior89The graduated runtime requests only Jazz's persistent driver and rejects boot before creating an10identity/database when secure context, OPFS, SharedWorker, Web Locks, or MessageChannel is missing.11There is no memory configuration or automatic fallback. UI separately reports:1213- capability eligibility;14- `persistent-driver-open` only after `createDb()` resolves;15- per-write local durability only after `WriteHandle.wait({ tier: "local" })`;16- `navigator.storage.persisted()` state and the result of an explicit persistence request.1718## Desktop preflight1920- capability report: secure context, OPFS available, SharedWorker available, Web Locks available;21- initial eviction-persistence state: not granted;22- a write updated both islands, survived reload, and survived explicit/concurrent client recreation;23- two same-origin pages and the exact Jazz control exercised the SharedWorker baseline in #7;24- production service worker reached `ready`, controlled the page, and installed a revisioned cache;25- with browser networking forced offline, a cold page reload rendered the prerendered shell;26- while still offline, a new local write appeared in both islands, reached local durability, and27 survived another offline reload plus a subsequent online reload;28- recursive build scan found no server-secret name or value in the client artifact.2930Returning online is recorded only as retained local behavior. The pinned Jazz API exposes no public31connection-state or convergence signal, so this evidence makes no transport-reconnection claim.3233This is preflight only. It does not replace the required physical iPhone and Android evidence.3435## Physical matrix status3637> Status as recorded at M1. The physical matrix has since run and graduated at M3; see DX-DEVICE-01,38> DX-DEVICE-UX-01, and DX-OFFLINE-01 in the developer-experience contract. Do not cite this table as39> current status.4041| Surface | Status |42| ----------------------- | -------------- |43| iPhone Safari tab | deferred to M3 |44| iPhone Home Screen app | deferred to M3 |45| Android Chrome 148+ tab | deferred to M3 |46| Android installed app | deferred to M3 |4748## M1 approval4950The product owner approved the M1 OPFS/PWA feasibility decision on 2026-07-15 from the stable HTTPS51artifact at <https://n.zip/2c6d/>. The live page hydrated both islands, reported a secure context,52OPFS, SharedWorker, Web Locks, and `persistent-driver-open`, retained a write across reload, and53preserved the 1 / 2 / 1 / 1 runtime cardinality.5455The host exposed one integration defect: its explicit `index.html` canonical redirect used HTTP,56which made a service-worker precache transaction redundant. Lofi now caches and falls back to the57canonical scope root (`./`) and reports a redundant worker as `failed`; an nzip host patch is being58prepared upstream. This does not change the durability decision.5960After republishing that workaround as artifact sequence 3, the live worker activated with scope61`https://n.zip/2c6d/`, installed the revisioned cache, controlled the next load, and rendered the62hydrated persistent-driver UI after a forced offline reload. The only offline console failure was63nzip's Cloudflare browser-analytics request; no application resource or hydration failed.6465This approval validates the M1 capability gate; it is not a claim that the physical matrix above66ran. The full checklist remains required for M3 production PWA hardening. The shared nzip origin is67also accepted only for OPFS/PWA feasibility, not as passkey or identity-isolation evidence.