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
{{ message }}
Repository navigation
[Bug]: Packaged desktop backend fails to start with Cannot find module 'zod/v4' after @cursor/sdk 1.0.38 #25840
The backend child exits immediately with Cannot find module 'zod/v4', required from app.asar/node_modules/@cursor/sdk/dist/cjs/index.js. The desktop app retries and then gives up, so there is no server.
@cursor/sdk 1.0.38 moved zod from dependencies to peerDependencies ("zod": "^3.25.0 || ^4.0.0"). zod is a runtime external of the server bundle (CURSOR_RUNTIME_DEPENDENCIES in scripts/lib/cli-external-packages.ts), but the desktop stage only receives the externals that apps/server/package.json lists (selectCliRuntimeExternalDependencies(serverDependencies)), and apps/server does not list zod. Before 1.0.38, zod reached the stage as a regular dependency of @cursor/sdk; now nothing staged depends on it, and app.asar ships @cursor/sdk without it.
No release is affected yet: v0.1.3 and the latest nightly (d2c440312e5f) predate #21074. The next nightly built from main will be the first to carry it.
macOS 26 (Apple Silicon), desktop nightly. Observed on a fork build that merged upstream main at 6bbb2d8508; the fork's changes to scripts/build-desktop-artifact.ts are limited to dev signing and a locale, and the dependency staging is identical to upstream. Linux and Windows builds were not checked, nor was the npx t3 CLI archive, which uses the same external selection but no electron-builder.
Add "zod": "^4.6.5" to apps/server/package.json dependencies (the version already in the lockfile). With that, app.asar contains node_modules/zod beside @cursor/sdk and the backend starts. A PR with this change and a regression test follows.
Confirmed on the official nightly 0.1.4-nightly.20261027.3766 (e109dc8), macOS 27.0 (Apple Silicon), desktop app with its built-in backend. The app auto-updated from 0.1.3-nightly.20261027.3754, which worked. After the update the window never appears: the backend child crashes on every retry (~10s apart) with the same error:
I checked the shipped app.asar: it has no node_modules/zod at all, and @cursor/sdk has no nested copy. #25841 should fix it. Until a fixed nightly ships, reinstalling 0.1.3-nightly.20261027.3754 works around it.
Found via t3 triage by Claude Opus 5.5 (claude-opus-5-5) in Claude Code.
Independently reproduced on the installed macOS ARM64 Nightly 0.1.4-nightly.20261027.3766, commit e109dc8d8941, on macOS 27.2 (26B118).
The main window never appears. Local server-child.log records MODULE_NOT_FOUND: Cannot find module 'zod/v4', required by app.asar/node_modules/@cursor/sdk/dist/cjs/index.js, then apps/server/dist/binCli-BH8BLs_H.mjs (Node.js v24.22.0). The backend exits with code 1 and retries approximately every 10 seconds.
Read-only inspection of the installed app.asar confirms that @cursor/sdk is version 1.0.38 and node_modules/zod is absent. This corroborates the report above on another macOS version.
Activity
fix(server): declare zod so the packaged desktop backend starts
jarrednorrisdev commentedon Oct 27, 2026
Confirmed on the official nightly 0.1.4-nightly.20261027.3766 (e109dc8), macOS 27.0 (Apple Silicon), desktop app with its built-in backend. The app auto-updated from 0.1.3-nightly.20261027.3754, which worked. After the update the window never appears: the backend child crashes on every retry (~10s apart) with the same error:
I checked the shipped
app.asar: it has nonode_modules/zodat all, and@cursor/sdkhas no nested copy. #25841 should fix it. Until a fixed nightly ships, reinstalling 0.1.3-nightly.20261027.3754 works around it.Found via
t3 triageby Claude Opus 5.5 (claude-opus-5-5) in Claude Code.Wulfgardr commentedon Oct 27, 2026
Independently reproduced on the installed macOS ARM64 Nightly 0.1.4-nightly.20261027.3766, commit
e109dc8d8941, on macOS 27.2 (26B118).The main window never appears. Local
server-child.logrecordsMODULE_NOT_FOUND: Cannot find module 'zod/v4', required byapp.asar/node_modules/@cursor/sdk/dist/cjs/index.js, thenapps/server/dist/binCli-BH8BLs_H.mjs(Node.js v24.22.0). The backend exits with code 1 and retries approximately every 10 seconds.Read-only inspection of the installed
app.asarconfirms that@cursor/sdkis version 1.0.38 andnode_modules/zodis absent. This corroborates the report above on another macOS version.t3dotgg commentedon Oct 27, 2026
on it
fix(desktop): run the packaged bundle self-check on macOS artifacts