close
Skip to content

fix: sandbox_allow_unsandboxed_exec should default to true on Windows #1525

Description

@chenmingwei23

Problem

On Windows, enabling Dev Fleet (and other features backed by MCP agent subprocesses) fails with a 500 / "Backend unavailable" error:

{"error": "app 'dev-fleet' has no reachable backend"}

kirocrew doctor shows all three MCP probes failing:

@kirocrew-cron:     FAIL  Sandbox backend unavailable and allow_unsandboxed_exec is not set. Probe detail: not Linux.
@kirocrew-core:     FAIL  Sandbox backend unavailable and allow_unsandboxed_exec is not set. Probe detail: not Linux.
@kirocrew-computer: FAIL  Sandbox backend unavailable and allow_unsandboxed_exec is not set. Probe detail: not Linux.

Root Cause

agent.sandbox_allow_unsandboxed_exec defaults to false in config/loader.py. On Windows there is no OS-level sandbox backend, so the worktree handler and MCP gateway both fail-closed — which means a fresh Windows install has zero functional MCP tooling out of the box, with no actionable error message.

Fix

Auto-detect the platform at config load time and default sandbox_allow_unsandboxed_exec to true when sys.platform == "win32". The fail-closed posture is correct on Linux (where a real sandbox backend exists); on Windows it is an unusable default.

Workaround (for now): manually set agent.sandbox_allow_unsandboxed_exec: true in ~/.kiro/crew/config.json and restart the gateway.

Impact

Every Windows user hitting this for the first time gets a mysterious 500 with no path to resolution. They must manually edit config.json to unblock basic functionality — terrible first-run experience.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: agentsACP runtime, sub-agents, session lifecyclearea: coreCore runtime utilities, config/paths, process singletonsbugSomething is not workingplatform: windowsWindows-specific

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions