[BUG] Cowork sandbox bash tool caps timeout_ms at 45000, no way to run longer commands

Open 💬 0 comments Opened Jul 3, 2026 by andrebuerger

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

Cowork's built in sandbox bash tool sets a hard maximum of timeout_ms = 45000 in its own input schema. Any value above that is rejected by input validation before the command even runs:

MCP error -32602: Input validation error: Invalid arguments for tool bash: [
  {
    "code": "too_big",
    "maximum": 45000,
    "type": "number",
    "inclusive": true,
    "exact": false,
    "message": "Number must be less than or equal to 45000",
    "path": ["timeout_ms"]
  }
]

So any command run through the built in sandbox is capped at 45 seconds no matter what the caller asks for. A command that takes longer gets killed at the cap. This blocks normal work like package installs, builds, backups, or any script that legitimately runs over 45s, and it forces the agent to hand roll workarounds like setsid ... & disown plus log file tailing.

This is separate from the general MCP timeout ceiling tracked in #73955 and #58687. This one is purely the sandbox tool's own schema limit.

What Should Happen?

  • Raise the 45000ms cap significantly, or make it configurable.
  • Ideally add a native background and poll mode so a long command can be started, detached, and polled for output, instead of agents having to build that by hand.

Error Messages/Logs

Asking for anything above the cap:

MCP error -32602: Input validation error ... "maximum": 45000 ... path: ["timeout_ms"]

Steps to Reproduce

  1. In Cowork, run a sandbox shell command that takes longer than 45s, for example echo start; sleep 70; echo end. It gets killed at the 45000ms mark.
  2. On the same tool, explicitly request a timeout_ms above 45000. You get the -32602 too_big validation error shown above. The schema enforces a hard maximum of 45000 regardless of the requested value.

Claude Model

Not sure / Multiple models

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

Cowork / Claude Desktop build 1.17377.1

Platform

Anthropic API

Operating System

Windows

Terminal/Shell

Non-interactive/CI environment

Additional Information

#73955 covers the separate MCP level ~60s timeout. Related upstream: #58687, #470.

View original on GitHub ↗