{"record":{"id":"adb856a5b8b3c612","repo":"n8n-io/n8n","slug":"local-computer-use-build-not-found-at-local-comp","errorCode":null,"errorMessage":"Local computer-use build not found at ${LOCAL_COMPUTER_USE_CLI}.\nBuild it first:\n  pnpm --filter @n8n/computer-use --filter @n8n/mcp-browser build\n\nOr pass --use-published-daemon to spawn the released package via npx instead.","messagePattern":"Local computer-use build not found at (.+?)\\.\nBuild it first:\n  pnpm --filter @n8n/computer-use --filter @n8n/mcp-browser build\n\nOr pass --use-published-daemon to spawn the released package via npx instead\\.","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/@n8n/instance-ai/evaluations/computer-use/daemon.ts","lineNumber":83,"sourceCode":"\t\tlogger.verbose(`[daemon] already paired, dir=${status.directory}`);\n\t\t// Auto-connect (N8N_EVAL_AUTO_BROWSER_CONNECT=1) is set on the daemon's\n\t\t// own process env at spawn-time, so it only takes effect when the eval\n\t\t// runner started the daemon. A pre-existing daemon won't have it.\n\t\tlogger.warn(\n\t\t\t'Reusing existing computer-use daemon. If it was not started by this eval runner, ' +\n\t\t\t\t'browser auto-connect may be inactive — you may need to click Connect in the ' +\n\t\t\t\t'extension manually when the browser session resets between scenarios.',\n\t\t);\n\t\treturn toInfo(status);\n\t}\n\n\tif (!opts.autoStart) {\n\t\tthrow new Error(noDaemonHint(opts.baseUrl));\n\t}\n\n\tconst usePublished = opts.usePublishedDaemon ?? false;\n\tif (!usePublished && !existsSync(LOCAL_COMPUTER_USE_CLI)) {\n\t\tthrow new Error(\n\t\t\t`Local computer-use build not found at ${LOCAL_COMPUTER_USE_CLI}.\\n` +\n\t\t\t\t'Build it first:\\n' +\n\t\t\t\t'  pnpm --filter @n8n/computer-use --filter @n8n/mcp-browser build\\n' +\n\t\t\t\t'\\n' +\n\t\t\t\t'Or pass --use-published-daemon to spawn the released package via npx instead.',\n\t\t);\n\t}\n\n\tconst sandboxDir = opts.daemonSandboxDir ?? join(opts.evalOutputDir, 'daemon-sandbox');\n\tawait mkdir(sandboxDir, { recursive: true });\n\n\tconst logPath = join(opts.evalOutputDir, 'daemon.log');\n\tconst { token } = await client.createGatewayLink();\n\n\tlogger.info(\n\t\t`Daemon not running — auto-starting (${usePublished ? 'published via npx' : 'local workspace build'}, sandbox: ${sandboxDir})`,\n\t);\n\tconst pid = await spawnDaemonDetached({","sourceCodeStart":65,"sourceCodeEnd":101,"githubUrl":"https://github.com/n8n-io/n8n/blob/5ac6606e81f67bb9534255570cd4e86fd8101eee/packages/@n8n/instance-ai/evaluations/computer-use/daemon.ts#L65-L101","documentation":"Thrown by `ensureDaemon()` when autoStart is true, `usePublishedDaemon` is false (the default), and the local workspace build of `@n8n/computer-use` is missing at the resolved path `packages/@n8n/computer-use/dist/cli.js`. The runner prefers the local build so in-progress changes to `@n8n/computer-use` and its workspace deps (`@n8n/mcp-browser`) are picked up; the error tells you to either build it or fall back to the published npm package.","triggerScenarios":"Fresh checkout where `pnpm install` ran but `pnpm build` (or `pnpm --filter @n8n/computer-use --filter @n8n/mcp-browser build`) has not. A `pnpm reset`/`git clean -fdx` that wiped `dist/`. Switching branches where `@n8n/computer-use` was added/removed. A failed partial build that produced some packages' `dist/` but not this one.","commonSituations":"First run of the computer-use eval suite on a new machine. After `pnpm reset --full`. In CI if the build step was skipped or cached as a miss without re-running.","solutions":["Build the local packages: `pnpm --filter @n8n/computer-use --filter @n8n/mcp-browser build`, then re-run the eval.","If you want to test the released artifact instead (e.g. reproducing a customer bug against the shipped version), pass `--use-published-daemon` to spawn `@n8n/computer-use` via npx.","If the build keeps failing, check `packages/@n8n/computer-use/package.json` and its tsconfig; a compile error there will prevent `dist/cli.js` from being emitted."],"exampleFix":"// before\n$ node cli.ts --base-url http://localhost:5678\n# Error: Local computer-use build not found at .../dist/cli.js\n\n// after (option A)\n$ pnpm --filter @n8n/computer-use --filter @n8n/mcp-browser build\n$ node cli.ts --base-url http://localhost:5678\n\n// after (option B)\n$ node cli.ts --base-url http://localhost:5678 --use-published-daemon","handlingStrategy":"validation","validationCode":"import { existsSync } from 'node:fs';\nconst LOCAL = resolve(__dirname, '../../../../../packages/@n8n/computer-use/dist/cli.js');\nif (!usePublishedDaemon && !existsSync(LOCAL)) {\n  throw new Error(`Build missing — run: pnpm --filter @n8n/computer-use --filter @n8n/mcp-browser build`);\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Add a `pnpm agent:setup` or repo build step to your onboarding so `dist/cli.js` exists before any eval run.","After `pnpm reset --full`, always rebuild before invoking evals.","In CI, depend on the build job, not just install."],"tags":["daemon","computer-use","build","monorepo","configuration"],"backgroundTag":null,"analyzedSha":"5ac6606e81f67bb9534255570cd4e86fd8101eee","analyzedAt":"2026-08-12T05:26:35.080Z","schemaVersion":2},"datasetVersion":"2026-08-12T18:17:37.767Z"}