8000 feat(browser): OPFS mode package tests, README and core pin (#441) by adityamukho · Pull Request #26 · project-minigraf/minigraf-wasm · GitHub
[go: up one dir, main page]

Skip to content

feat(browser): OPFS mode package tests, README and core pin (#441) - #26

Merged
adityamukho merged 14 commits into
v3from
feat/441-browser-opfs
Nov 17, 2026
Merged

adityamukho merged 14 commits into
v3from
feat/441-browser-opfs

Conversation

@adityamukho
Copy link
Copy Markdown
Contributor

Companion to project-minigraf/minigraf#899, which adds BrowserDb.openOpfs. Refs project-minigraf/minigraf#441.

What changes

  • Core pin moves to the head of #899's branch. Re-pin to the merge commit once #899 merges.
  • Packaged consumer tests use a real dedicated worker, and cover:
    • open, write and reopen;
    • the lock across two workers, released on close() and on termination;
    • the main-thread rejection (API-026);
    • IndexedDB in a worker;
    • generated free() of the database and its dependents;
    • worker termination at six points in a stream of sequential commits, where the page records each acknowledgement and checks for a gap-free prefix that includes every acknowledged commit;
    • import interruption at four points, checking old or new, whole.
  • CI runs these on Chromium, Firefox and WebKit.
  • README covers OPFS mode, a complete module-worker example with postMessage, close(), choosing a mode, and moving a database between modes by export/import. readme_sync.py covers the example.

Verification

  • Chromium 140 (Playwright) and Firefox 159 (WebDriver): 54 checks pass on each.
  • All four readme_sync.py checks pass.
  • WebKit runs only in CI here (Playwright's WebKit is not installed locally).

🤖 Generated with Claude Code

https://claude.ai/code/session_01H2a7QjCHpikfsg5qwAV1p9

adityamukho and others added 14 commits November 14, 2026 09:44
…441)

Pin the OPFS core and cover cross-worker locking, complete commit prefixes, interrupted imports, and the module-worker example in all three browser engines.

Refs #441

Co-Authored-By: GPT-6 <noreply@openai.com>
Bound retries of only STG-026 to ten seconds during termination recovery, accommodating asynchronous browser teardown.

Refs #441

Co-Authored-By: GPT-6 <noreply@openai.com>
Select the local core revision containing the OPFS implementation, browser validation and bounded-memory evidence. The core branch must be published before fetching this revision remotely.

Refs #441

Co-Authored-By: GPT-6 <noreply@openai.com>
…441)

Exercise generated free methods while cursors, prepared queries and a staged transaction retain the OPFS owner. Verify lock release and unchanged durable bytes after every owner is freed. Pin the corrected core revision and document the actual database/staging entry mapping and nonempty import admission rule.

Refs #441

Co-Authored-By: Codex (GPT-6.1-sol) <noreply@openai.com>
Pin the exact core revision containing strict import admission, recovered exports and complete lifecycle and recovery fault coverage. Retain the Git dependency source and existing dependency versions.

Refs #441

Co-Authored-By: Codex (GPT-6.1-sol) <noreply@openai.com>
Describe every admitted OPFS import image and pin the core revision preserving shared foreign-file errors. Keep the Git dependency source and existing dependency versions.

Refs #441

Co-Authored-By: Codex (GPT-6) <noreply@openai.com>
Refs #441

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01H2a7QjCHpikfsg5qwAV1p9
Refs #441

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01H2a7QjCHpikfsg5qwAV1p9
Playwright's Linux WebKit has no navigator.storage.getDirectory() in a
dedicated worker, so openOpfs rejects with API-026 there, as specified.
The OPFS page now probes a worker first and reports that rejection; the
driver accepts it only on WebKit, prints it as a limitation, and still
requires the IndexedDB-in-a-worker check. A missing OPFS on Chromium or
Firefox still fails the run.

Refs project-minigraf/minigraf#441

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01H2a7QjCHpikfsg5qwAV1p9
…(#441)

Refs #441

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01H2a7QjCHpikfsg5qwAV1p9
WebKit denies OPFS in Playwright's ephemeral context, as in a private window.

Refs #441

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01H2a7QjCHpikfsg5qwAV1p9
Refs #441

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01H2a7QjCHpikfsg5qwAV1p9
Refs #441

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01H2a7QjCHpikfsg5qwAV1p9
@adityamukho
adityamukho merged commit b7262f9 into v3 Nov 17, 2026
19 of 20 checks passed
@adityamukho
adityamukho deleted the feat/441-browser-opfs branch November 17, 2026 14:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

0