You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
test(e2e): route every context.db open through openTestDb with busy_timeout
The e2e suite runs many files in parallel against a shared context.db while the
plugin under test writes to it. Handles opened with the default busy_timeout=0
fail immediately with SQLITE_BUSY the instant another connection holds the write
lock, surfacing as flaky 'database is locked' failures (memory-injection,
cache-stability cascade) rather than real regressions.
Most write-handle opens set the pragma inline, but that left the footgun live:
memory-injection and all the pi-* direct opens had no timeout, and one
pi-todo-synthesis open was missing it too. Add one openTestDb() helper that
always sets busy_timeout and route every direct open (reader and writer) through
it, deleting the now-redundant inline pragmas. A bare new Database in a test can
no longer reintroduce the flake.
"SELECT id, json_extract(data, '$.role') AS role, json_extract(data, '$.finish') AS finish, json_extract(data, '$.summary') AS summary FROM message WHERE session_id = ? ORDER BY id DESC LIMIT 6",
0 commit comments