From 707190ef37c9e40146c1307c3912e793aabc8ed8 Mon Sep 17 00:00:00 2001 From: Kevin De Porre Date: Thu, 19 Mar 2026 17:29:18 +0100 Subject: [PATCH] fix: resolve Electron e2e test timeout failures in CI MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The Electron persisted collection conformance suite (113 tests) was failing in CI because TANSTACK_DB_ELECTRON_E2E_ALL=1 caused every IPC call to spawn a separate Electron process (~2-3s each). All 6 collections shared a single serialized invoke queue, so background getStreamPosition calls queued up and exceeded the 5000ms per-request timeout before being dequeued. - Remove TANSTACK_DB_ELECTRON_E2E_ALL=1 from CI workflow. The runtime bridge e2e test (3 tests) already validates real Electron IPC independently — it always spawns real processes regardless of the env var. The conformance suite validates persistence adapter correctness, which the fast in-process mode covers fully. - Increase timeoutMs to 90s in full e2e mode as a safety net for local test:e2e:all usage. Co-Authored-By: Claude Opus 4.6 (1M context) --- .github/workflows/e2e-tests.yml | 4 ++-- .../tests/electron-persisted-collection.e2e.test.ts | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/e2e-tests.yml b/.github/workflows/e2e-tests.yml index abb11c048..6558b4589 100644 --- a/.github/workflows/e2e-tests.yml +++ b/.github/workflows/e2e-tests.yml @@ -67,10 +67,10 @@ jobs: cd packages/db-node-sqlite-persisted-collection pnpm test:e2e - - name: Run Electron SQLite persisted collection E2E tests (full bridge) + - name: Run Electron SQLite persisted collection E2E tests run: | cd packages/db-electron-sqlite-persisted-collection - TANSTACK_DB_ELECTRON_E2E_ALL=1 pnpm test:e2e + pnpm test:e2e - name: Run Cloudflare Durable Object persisted collection E2E tests run: | diff --git a/packages/db-electron-sqlite-persisted-collection/tests/electron-persisted-collection.e2e.test.ts b/packages/db-electron-sqlite-persisted-collection/tests/electron-persisted-collection.e2e.test.ts index b1710b779..1dc74a35f 100644 --- a/packages/db-electron-sqlite-persisted-collection/tests/electron-persisted-collection.e2e.test.ts +++ b/packages/db-electron-sqlite-persisted-collection/tests/electron-persisted-collection.e2e.test.ts @@ -122,6 +122,7 @@ function createPersistedCollection( ): PersistedCollectionHarness { const persistence = createElectronSQLitePersistence({ invoke, + timeoutMs: isElectronFullE2EEnabled() ? 90_000 : undefined, }) let seedSequence = 0 const seedPersisted = async (rows: Array): Promise => {