{"record":{"id":"25c8b5ac24326091","repo":"paperclipai/paperclip","slug":"local-process-filesystem-and-network-scopes-are-cu","errorCode":null,"errorMessage":"Local process filesystem and network scopes are currently supported only on Linux.","messagePattern":"Local process filesystem and network scopes are currently supported only on Linux\\.","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/adapter-utils/src/local-process-sandbox.ts","lineNumber":348,"sourceCode":"  process.on(\"SIGTERM\", () => forward(\"SIGTERM\"));\n  process.on(\"SIGINT\", () => forward(\"SIGINT\"));\n  child.on(\"exit\", (code, signal) => server.close(() => {\n    if (signal) process.kill(process.pid, signal);\n    else process.exit(code == null ? 1 : code);\n  }));\n});\n`;\n  return source.trimStart();\n}\n\nexport async function buildLocalProcessSandboxSpawnTarget(input: {\n  executable: string;\n  args: string[];\n  cwd: string;\n  options: LocalProcessSandboxOptions;\n}): Promise<LocalProcessSandboxSpawnTarget> {\n  if (process.platform !== \"linux\") {\n    throw new Error(\"Local process filesystem and network scopes are currently supported only on Linux.\");\n  }\n  const filesystemScope = input.options.filesystemScope ?? null;\n  const networkScope = input.options.networkScope ?? null;\n  if (!filesystemScope && !networkScope) throw new Error(\"Local process sandbox requires a filesystem or network scope.\");\n\n  const workspaceDir = normalizeAbsolutePath(input.options.workspaceDir, \"Sandbox workspaceDir\");\n  const cwd = normalizeAbsolutePath(input.cwd, \"Sandbox cwd\");\n  if (filesystemScope === \"workspace\") {\n    const relativeCwd = path.relative(workspaceDir, cwd);\n    if (relativeCwd.startsWith(\"..\") || path.isAbsolute(relativeCwd)) {\n      throw new Error(`Sandbox cwd \"${cwd}\" must be inside workspaceDir \"${workspaceDir}\".`);\n    }\n    const outboundRestorePaths = (input.options.outboundRestorePaths ?? []).map((candidate, index) =>\n      normalizeAbsolutePath(candidate, `Sandbox outboundRestorePaths[${index}]`));\n    for (const [index, extraPath] of (input.options.extraPaths ?? []).entries()) {\n      if (extraPath.access !== \"rw\") continue;\n      const normalizedExtraPath = normalizeAbsolutePath(extraPath.path, `Sandbox extraPaths[${index}].path`);\n      const relativeToWorkspace = path.relative(workspaceDir, normalizedExtraPath);","sourceCodeStart":330,"sourceCodeEnd":366,"githubUrl":"https://github.com/paperclipai/paperclip/blob/120ae5428fa29bee300bcf806491cd4d965fbb7c/packages/adapter-utils/src/local-process-sandbox.ts#L330-L366","documentation":"buildLocalProcessSandboxSpawnTarget uses Linux sandboxing primitives (bubblewrap); on any other platform the filesystem/network scope feature is unsupported and refused.","triggerScenarios":"Thrown at packages/adapter-utils/src/local-process-sandbox.ts:348 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Run local process confinement on Linux.","Use a remote/sandbox execution target on non-Linux platforms."],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"120ae5428fa29bee300bcf806491cd4d965fbb7c","analyzedAt":"2026-08-18T22:49:45.177Z","contentChangedAt":"2026-08-18T22:49:45.177Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}