Skip to content

test(fork): run the readerAfter pinned-WAL test with 1 KiB pages - #206

Merged
fireboltdude1357 merged 1 commit into
patch/wal-pinned-writesfrom
fix/wal-pinned-writes-pagesize-6f54322
Nov 6, 2026
Merged

fireboltdude1357 merged 1 commit into
patch/wal-pinned-writesfrom
fix/wal-pinned-writes-pagesize-6f54322

Conversation

@fireboltdude1357

Copy link
Copy Markdown
Owner

The fork's nightly build still fails on the Linux leg after #205:

FAIL packages/shared/src/nodeSqliteClient.test.ts > keeps admitting writes while an outside read transaction pins the WAL (readerAfter=127)
AssertionError: write 127 is held by admission while an outside reader pins the WAL (135181352 bytes, journal_size_limit 33554432)

Write 127 is the one that crosses upstream's 32,768-frame ceiling, and in this case the reader opens only after it. So this isn't the pinned-reader case. With 4 KiB pages the WAL is 128 MiB at the ceiling. On omarchy the checkpoint worker took long enough to report that write blocked twice, which the test treats as a held write. With the old 10,000-frame ceiling the same crossing happened at about 40 MiB, and omarchy passed.

The readerAfter test now sets PRAGMA page_size = 1024 before WAL mode. A 1 MiB row is then about 1,030 frames, so the 32nd row crosses the ceiling, with about 32 MiB of WAL. The reader opens after 31 rows, just past the ceiling, as readerAfter: 38 did before. The loop is back to 64 rows. The TRUNCATE retry test passed on omarchy, so it keeps 4 KiB pages and 126 rows. With 1 KiB pages it timed out here.

On a stack of upstream 98b930f with all 23 patches and this branch, the 26 tests in nodeSqliteClient.test.ts pass three times in a row on stl-wsl, in about 16 s. The fork build runs them on omarchy.

Made by Claude Opus 5.5 in Claude Code.

🤖 Generated with Claude Code

At upstream's 32,768-frame ceiling and 4 KiB pages, the WAL reaches
128 MiB before the ceiling. On omarchy, the readerAfter case's crossing
write was then reported blocked twice while the worker checkpointed it,
which the test reads as a held write. With 1 KiB pages the ceiling sits
near 32 MiB, as with the old 10,000-frame ceiling, and the row counts go
back near their old values. The TRUNCATE retry test, which passed on
omarchy, keeps 4 KiB pages.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@fireboltdude1357
fireboltdude1357 merged commit f4e1f17 into patch/wal-pinned-writes Nov 6, 2026
2 checks passed
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