{"record":{"id":"b1b759138269f5ff","repo":"slopus/happy","slug":"claudelocal-sandbox-is-not-supported-on-windows","errorCode":null,"errorMessage":"[ClaudeLocal] Sandbox is not supported on Windows; continuing without sandbox.","messagePattern":"\\[ClaudeLocal\\] Sandbox is not supported on Windows; continuing without sandbox\\.","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"packages/happy-cli/src/claude/claudeLocal.ts","lineNumber":280,"sourceCode":"                ...opts.claudeEnvVars\n            }\n\n            if (opts.mcpServers && Object.keys(opts.mcpServers).length > 0) {\n                ensureLocalProxyBypass(env);\n            }\n\n            logger.debug(`[ClaudeLocal] Spawning launcher: ${claudeCliPath}`);\n            logger.debug(`[ClaudeLocal] Args: ${JSON.stringify(args)}`);\n\n            (async () => {\n                let cleanupSandbox: (() => Promise<void>) | null = null;\n                let spawnCommand: string | null = null;\n                let spawnArgs: string[] = [claudeCliPath, ...args];\n                let spawnWithShell = false;\n\n                if (opts.sandboxConfig?.enabled) {\n                    if (process.platform === 'win32') {\n                        logger.warn('[ClaudeLocal] Sandbox is not supported on Windows; continuing without sandbox.');\n                    } else {\n                        try {\n                            cleanupSandbox = await initializeSandbox(opts.sandboxConfig, opts.path);\n\n                            if (!spawnArgs.includes('--dangerously-skip-permissions')) {\n                                spawnArgs = [...spawnArgs, '--dangerously-skip-permissions'];\n                            }\n\n                            const fullCommand = [\n                                'node',\n                                ...spawnArgs.map((arg) => quoteShellArg(arg)),\n                            ].join(' ');\n\n                            spawnCommand = await wrapCommand(fullCommand);\n                            spawnWithShell = true;\n\n                            logger.info(\n                                `[ClaudeLocal] Sandbox enabled: workspace=${opts.sandboxConfig.workspaceRoot ?? opts.path}, network=${opts.sandboxConfig.networkMode}`,","sourceCodeStart":262,"sourceCodeEnd":298,"githubUrl":"https://github.com/slopus/happy/blob/b824cd0a4681d41af631a8e422a813873e4455b0/packages/happy-cli/src/claude/claudeLocal.ts#L262-L298","documentation":"In claudeLocal, when the user requested sandbox (sandboxConfig.enabled) on Windows, happy logs that sandboxing is unsupported and proceeds to spawn Claude without sandbox initialization. The session runs unsandboxed rather than failing.","triggerScenarios":"Launching happy claude with a sandbox config where enabled=true while process.platform === 'win32' (native Windows, not WSL).","commonSituations":"Settings synced from a macOS/Linux machine to a Windows laptop, or users enabling sandbox globally in ~/.happy settings and then running on Windows.","solutions":["Run happy inside WSL2, where the Unix sandbox path is used.","Disable sandbox in settings (set sandboxConfig.enabled=false) to silence the warning and make the behavior explicit.","If sandbox isolation is a hard requirement, move the workflow to a supported platform (macOS/Linux)."],"exampleFix":"// before (~/.happy/settings.json)\n{ \"sandboxConfig\": { \"enabled\": true } }\n// after (on Windows)\n{ \"sandboxConfig\": { \"enabled\": false } }","handlingStrategy":"validation","validationCode":"if (process.platform === 'win32' && settings.sandboxConfig?.enabled) {\n  console.warn('Sandbox requested on Windows: not supported. Run under WSL2 or disable sandboxConfig.enabled.');\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Gate sandbox-enabled settings per-OS (only enable on macOS/Linux).","Use WSL2 on Windows if sandbox isolation matters.","Set sandboxConfig.enabled=false explicitly on Windows machines.","Don't sync sandbox settings blindly across platforms with dotfile managers."],"tags":["windows","sandbox","platform-compatibility"],"backgroundTag":"unsupported-platform-feature","analyzedSha":"b824cd0a4681d41af631a8e422a813873e4455b0","analyzedAt":"2026-08-31T23:12:36.205Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-08T05:18:18.240Z"}