[Bug] MCP computer-use screenshot timeout with iOS Simulator: Swift continuation leak
Bug Description
Bug Report: computer-use MCP screenshot fails with iOS Simulator
The mcp__computer-use__screenshot tool consistently times out (30s) and crashes when the iOS
Simulator is the only granted application. The error from the MCP server is:
SWIFT TASK CONTINUATION MISUSE:
captureScreenWithExclusion(displayId:width:height:allowedBundleIds:jpegQuality:) leaked its
continuation without resuming it. This may cause tasks waiting on it to remain suspended
forever.
Repro steps:
- Request access for Simulator app via request_access
- Open Simulator with a booted device
- Call screenshot
- Tool fails with 30s timeout every time
What I tried:
- Adding Finder to the allowlist alongside Simulator
- Rebooting the simulator
- Switching simulator devices (iPhone 17 Pro iOS 26.4, iPhone 16 iOS 18.1)
- Waiting before screenshotting
- All failed with the same continuation misuse error
Expected behavior: Screenshot should capture the Simulator window like any other macOS app.
Workaround: xcrun simctl io <device> screenshot works fine for capturing the simulator screen,
but then I can't use left_click because the MCP coordinates are relative to its own screenshot —
so I can see but not interact.
Suggestion: Could the MCP fall back to a full-screen capture (without the exclusion compositor
filter) when captureScreenWithExclusion fails? Or special-case the Simulator's bundle ID since
it renders content through a non-standard compositor layer?
Environment: macOS Darwin 25.3.0, Xcode with iOS Simulator, Claude Code CLI
Environment Info
- Platform: darwin
- Terminal: Apple_Terminal
- Version: 2.1.87
- Feedback ID: 24dcd4bd-101c-4364-9f51-44d67d7a763b
Errors
[{"error":"Error: NON-FATAL: Lock acquisition failed for /Users/eliasmunk/.local/share/claude/versions/2.1.87 (expected in multi-process scenarios)\n at _p_ (/$bunfs/root/src/entrypoints/cli.js:2851:2138)\n at Vn6 (/$bunfs/root/src/entrypoints/cli.js:2851:1218)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-03-30T19:51:31.532Z"},{"error":"Error: Request was aborted.\n at gv_ (/$bunfs/root/src/entrypoints/cli.js:1365:16708)\n at next (native:1:11)\n at Gy9 (/$bunfs/root/src/entrypoints/cli.js:7572:8934)\n at next (native:1:11)\n at Ly9 (/$bunfs/root/src/entrypoints/cli.js:7577:10737)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-03-30T20:12:28.915Z"},{"error":"AxiosError: Request failed with status code 404\n at _B (/$bunfs/root/src/entrypoints/cli.js:144:1194)\n at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:149:12745)\n at emit (node:events:92:22)\n at endReadableNT (internal:streams/readable:861:50)\n at processTicksAndRejections (native:7:39)\n at request (/$bunfs/root/src/entrypoints/cli.js:151:2467)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-03-30T20:17:43.290Z"},{"error":"McpToolCallError: Output exceeds 15000 character limit (20003 characters). Try specifying an even smaller depth parameter or use ref_id to focus on a specific element.\n at Mh7…
Note: Content was truncated.
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗