chore(core): drop unused graphql-compose-json and lru-cache dependencies#215
Conversation
|
This pull request is part of a Mergify stack:
|
Two CI failures on PR #215 (same root causes as #214): 1. liveServerEffortGraph.test.ts crashed with ERR_DLOPEN_FAILED on the watcher.node native addon when run after liveServer.test.ts. AVA 4 uses worker_threads; a native NAPI addon loaded in one worker leaves process-level state that prevents re-initialization in the next worker. Fix: move the @parcel/watcher import from the static top-level import in liveServer.ts to a dynamic import() inside the if (options.watch) branch. 2. live-bridge.test.ts › no journal publish before the live reindex commits failed with ENOENT on .journal/txns. The polling loop called readdir() without a try/catch; if mutate()'s async chain had not yet run recoverJournal() (which creates the directory) within the first poll window, the uncaught error failed the test. Fix: wrap readdir in try/catch and continue polling on ENOENT. Also increase budget from 20*5 ms to 50*10 ms (500 ms total) for headroom on slow CI runners. Change-Id: I4628b7b19c887384574f4b0e689266ef6fcdffc2
686d768 to
3a695d7
Compare
Revision history
|
There was a problem hiding this comment.
CI Fix Applied
Root cause: Two pre-existing test failures were inherited from the parent commit e15042a (PR #214) and carried through into this PR's commit 3a695d7.
Failing checks
test (20.x, ubuntu-latest): 1 test failed (live-bridge.test.ts) + 1 uncaught exception (liveServerEffortGraph.test.ts)test (22.x, ubuntu-latest): 1 uncaught exception (liveServerEffortGraph.test.ts)
Issue 1 — ERR_DLOPEN_FAILED in liveServerEffortGraph.test.ts
The static top-level import { subscribe } from '@parcel/watcher' in liveServer.ts caused a native NAPI addon (watcher.node) to load in the first AVA worker. AVA 4 uses worker_threads; once the addon is loaded in one worker it cannot be re-initialized in a second worker, crashing liveServerEffortGraph.test.ts with Module did not self-register.
Fix: Moved subscribe to a dynamic await import('@parcel/watcher') inside the if (options.watch) block — the addon is now never loaded in workers that don't use watch mode.
Issue 2 — ENOENT on .journal/txns in live-bridge.test.ts
The polling loop in the no journal publish before the live reindex commits test called readdir() on .journal/txns without a try/catch. On slow CI runners the recoverJournal() call (which creates the directory) had not completed within the first 5 ms window, causing an uncaught ENOENT.
Fix: Wrapped readdir in try/catch and continue on ENOENT. Also increased the budget from 20 × 5 ms to 50 × 10 ms (500 ms total) for headroom on slow runners.
Verification
Full AVA suite ran locally: 293 tests passed, no failures.
Commit pushed
Fix commit 686d768 was pushed to this PR's branch. These two issues were also previously fixed for PR #214 — the fix should ideally be incorporated into commit e15042a (which introduced both the liveServer.ts static import and the live-bridge.test.ts polling loop) using mergify stack push when credentials are available.
Sent by Cursor Automation: Flatbread - Fix CI
PRs #211 and #213 removed the only consumer paths: the nested-provider filter and the config-keyed schema cache. Removing their manifests and lockfile entries keeps @flatbread/core's runtime contract accurate. Verification: pnpm typecheck; pnpm build; pnpm test:ava (293 passed); pnpm -F @flatbread/codegen exec vitest run (45 passed); pnpm -F @flatbread/utils exec vitest run (7 passed); pnpm lint:fix:fast. Co-authored-by: Cursor <[email protected]> Change-Id: I6d9ecf9f45aea182e7a94ebfb962c46425167892
e15042a to
a3ee014
Compare
3a695d7 to
0b8d6b0
Compare
|
@Mergifyio queue |
Merge Queue Status
This pull request spent 47 minutes 56 seconds in the queue, including 4 minutes 34 seconds running CI. Required conditions to merge
|
…graph/drop-unused-graphql-compose-json-lru-cache-deps--6d9ecf9f


PRs #211 and #213 removed the only consumer paths: the nested-provider filter and the config-keyed schema cache. Removing their manifests and lockfile entries keeps @flatbread/core's runtime contract accurate.
Verification: pnpm typecheck; pnpm build; pnpm test:ava (293 passed); pnpm -F @flatbread/codegen exec vitest run (45 passed); pnpm -F @flatbread/utils exec vitest run (7 passed); pnpm lint:fix:fast.
Co-authored-by: Cursor [email protected]
Depends-On: #214