claude-code - 💡(How to fix) Fix [BUG]Cowork: guest Claude Code exits with "Failed to create bridge sockets after 5 attempts" (code 1, ~1s after spawn) [2 comments, 3 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#49467Fetched 2026-04-17 08:40:21
View on GitHub
Comments
2
Participants
3
Timeline
7
Reactions
0
Author
Timeline (top)
labeled ×4commented ×2closed ×1

Every Cowork session on my machine fails the same way: the VM boots cleanly, the guest connects, SDK
installs, OAuth is approved, the Claude Code process spawns — then immediately exits with code 1 after ~1 second, emitting Error: Failed to create bridge sockets after 5 attempts on stderr. No user code
ever runs.

This has been 100% reproducible across ~12 session attempts today, all failing identically.

Environment

  • Claude Desktop: 1.3036.0 (build cf521c, released 2026-04-16T16:17:33Z)
  • Claude account email: [email protected]
  • Claude Code (in VM / guest SDK): 2.1.111
  • Claude Code (host, Homebrew): 2.1.92
  • VM bundle: 5680b11bcdab215cccf07e0c0bd1bd9213b0c25d
  • macOS: 26.3 (build 25D125)
  • Hardware: Apple Silicon (M2, arm64)
  • Kernel: Darwin 25.3.0

Reproduction

  1. Open Claude Desktop.
  2. Start any new Cowork session (any trusted folder; see "What I tried" below).
  3. Session immediately errors with Claude Code process exited with code 1.

Relevant log excerpts

From ~/Library/Logs/Claude/cowork_vm_node.log — a typical failed session:

[VM:start] Beginning startup, bundlePath=.../vm_bundles/claudevm.bundle                                 
[VM:start] Bundle version: 5680b11bcdab215cccf07e0c0bd1bd9213b0c25d                                     
[VM:steps] vm_boot completed (176ms)                                                                    
[VM:steps] guest_vsock_connect completed (5550ms)                                                       
[VM:steps] guest_ready completed (402ms)                                                                
[VM:steps] install_ca_certificates completed (0ms)                                                      
[VM] API reachability: REACHABLE                                                                        
[VM:steps] sdk_install completed (0ms)                                                                  
[VM:start] Startup complete, total time: 7209ms                                                         
[Spawn:config] Creating spawn function for process=cool-magical-curie, isResume=false, mounts=7         
[Spawn:vm] OAuth token approved with MITM proxy                                                         
[Spawn:vm] Spawn succeeded in 50ms                                                                      
[vm-stderr 2e50647d] Error: Failed to create bridge sockets after 5 attempts                            
[Process:2e50647d...] Exited, code=1, signal=null, duration=1119ms, oom=false

Same Failed to create bridge sockets after 5 attempts error appears on every one of the ~12 session
attempts in the log today (session IDs: c99c2045, c37c1e7f, 84a0a66a, 373e9a91, c7c43b8e, 0995571f,
924937d0, 57e75560, c2ab895a, ed194367, a8d5711c, 2e50647d).

What I tried

  • Cleared ~/Library/Application Support/Claude/{Cache,vm_bundles,sessions,local-agent-mode-sessions}
    and relaunched → same error, new session name.
  • Changed localAgentModeTrustedFolders in claude_desktop_config.json from ~/Desktop/untitled folder (which had a space and was on a Desktop with iCloud sync history) to a clean local path
    ~/Documents/cowork → same error, new session name.

Failure mode is identical before and after both attempts.

Notes

  • Host-side components all look healthy: VM boots in ~176ms, guest vsock connects, networking reaches
    CONNECTED, API is REACHABLE, SDK install completes, OAuth approval succeeds, process spawn succeeds in 50ms.
  • The failure is strictly inside the guest Claude Code binary when it tries to set up its bridge
    sockets.
  • Not a stale-install issue: Claude Desktop 1.3036.0 build cf521c was released 2026-04-16 — the same day as this report.
  • Likely not the same root cause as #23991 / #24190 / #24483 / #24549 (those looked VM-provisioning
    related; my VM provisions fine).

Error Message

[VM:start] Beginning startup, bundlePath=.../vm_bundles/claudevm.bundle
[VM:start] Bundle version: 5680b11bcdab215cccf07e0c0bd1bd9213b0c25d
[VM:steps] vm_boot completed (176ms)
[VM:steps] guest_vsock_connect completed (5550ms)
[VM:steps] guest_ready completed (402ms)
[VM:steps] install_ca_certificates completed (0ms)
[VM] API reachability: REACHABLE
[VM:steps] sdk_install completed (0ms)
[VM:start] Startup complete, total time: 7209ms
[Spawn:config] Creating spawn function for process=cool-magical-curie, isResume=false, mounts=7
[Spawn:vm] OAuth token approved with MITM proxy
[Spawn:vm] Spawn succeeded in 50ms
[vm-stderr 2e50647d] Error: Failed to create bridge sockets after 5 attempts
[Process:2e50647d...] Exited, code=1, signal=null, duration=1119ms, oom=false

Root Cause

  • Host-side components all look healthy: VM boots in ~176ms, guest vsock connects, networking reaches
    CONNECTED, API is REACHABLE, SDK install completes, OAuth approval succeeds, process spawn succeeds in 50ms.
    • The failure is strictly inside the guest Claude Code binary when it tries to set up its bridge
      sockets.
    • Not a stale-install issue: Claude Desktop 1.3036.0 build cf521c was released 2026-04-16 — the same day as this report.
    • Likely not the same root cause as #23991 / #24190 / #24483 / #24549 (those looked VM-provisioning
      related; my VM provisions fine).

Code Example

[VM:start] Beginning startup, bundlePath=.../vm_bundles/claudevm.bundle                                 
  [VM:start] Bundle version: 5680b11bcdab215cccf07e0c0bd1bd9213b0c25d                                     
  [VM:steps] vm_boot completed (176ms)                                                                    
  [VM:steps] guest_vsock_connect completed (5550ms)                                                       
  [VM:steps] guest_ready completed (402ms)                                                                
  [VM:steps] install_ca_certificates completed (0ms)                                                      
  [VM] API reachability: REACHABLE                                                                        
  [VM:steps] sdk_install completed (0ms)                                                                  
  [VM:start] Startup complete, total time: 7209ms                                                         
  [Spawn:config] Creating spawn function for process=cool-magical-curie, isResume=false, mounts=7         
  [Spawn:vm] OAuth token approved with MITM proxy                                                         
  [Spawn:vm] Spawn succeeded in 50ms                                                                      
  [vm-stderr 2e50647d] Error: Failed to create bridge sockets after 5 attempts                            
  [Process:2e50647d...] Exited, code=1, signal=null, duration=1119ms, oom=false

---
RAW_BUFFERClick to expand / collapse

Preflight Checklist

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

What's Wrong?

Summary

Every Cowork session on my machine fails the same way: the VM boots cleanly, the guest connects, SDK
installs, OAuth is approved, the Claude Code process spawns — then immediately exits with code 1 after ~1 second, emitting Error: Failed to create bridge sockets after 5 attempts on stderr. No user code
ever runs.

This has been 100% reproducible across ~12 session attempts today, all failing identically.

Environment

  • Claude Desktop: 1.3036.0 (build cf521c, released 2026-04-16T16:17:33Z)
  • Claude account email: [email protected]
  • Claude Code (in VM / guest SDK): 2.1.111
  • Claude Code (host, Homebrew): 2.1.92
  • VM bundle: 5680b11bcdab215cccf07e0c0bd1bd9213b0c25d
  • macOS: 26.3 (build 25D125)
  • Hardware: Apple Silicon (M2, arm64)
  • Kernel: Darwin 25.3.0

Reproduction

  1. Open Claude Desktop.
  2. Start any new Cowork session (any trusted folder; see "What I tried" below).
  3. Session immediately errors with Claude Code process exited with code 1.

Relevant log excerpts

From ~/Library/Logs/Claude/cowork_vm_node.log — a typical failed session:

[VM:start] Beginning startup, bundlePath=.../vm_bundles/claudevm.bundle                                 
[VM:start] Bundle version: 5680b11bcdab215cccf07e0c0bd1bd9213b0c25d                                     
[VM:steps] vm_boot completed (176ms)                                                                    
[VM:steps] guest_vsock_connect completed (5550ms)                                                       
[VM:steps] guest_ready completed (402ms)                                                                
[VM:steps] install_ca_certificates completed (0ms)                                                      
[VM] API reachability: REACHABLE                                                                        
[VM:steps] sdk_install completed (0ms)                                                                  
[VM:start] Startup complete, total time: 7209ms                                                         
[Spawn:config] Creating spawn function for process=cool-magical-curie, isResume=false, mounts=7         
[Spawn:vm] OAuth token approved with MITM proxy                                                         
[Spawn:vm] Spawn succeeded in 50ms                                                                      
[vm-stderr 2e50647d] Error: Failed to create bridge sockets after 5 attempts                            
[Process:2e50647d...] Exited, code=1, signal=null, duration=1119ms, oom=false

Same Failed to create bridge sockets after 5 attempts error appears on every one of the ~12 session
attempts in the log today (session IDs: c99c2045, c37c1e7f, 84a0a66a, 373e9a91, c7c43b8e, 0995571f,
924937d0, 57e75560, c2ab895a, ed194367, a8d5711c, 2e50647d).

What I tried

  • Cleared ~/Library/Application Support/Claude/{Cache,vm_bundles,sessions,local-agent-mode-sessions}
    and relaunched → same error, new session name.
  • Changed localAgentModeTrustedFolders in claude_desktop_config.json from ~/Desktop/untitled folder (which had a space and was on a Desktop with iCloud sync history) to a clean local path
    ~/Documents/cowork → same error, new session name.

Failure mode is identical before and after both attempts.

Notes

  • Host-side components all look healthy: VM boots in ~176ms, guest vsock connects, networking reaches
    CONNECTED, API is REACHABLE, SDK install completes, OAuth approval succeeds, process spawn succeeds in 50ms.
  • The failure is strictly inside the guest Claude Code binary when it tries to set up its bridge
    sockets.
  • Not a stale-install issue: Claude Desktop 1.3036.0 build cf521c was released 2026-04-16 — the same day as this report.
  • Likely not the same root cause as #23991 / #24190 / #24483 / #24549 (those looked VM-provisioning
    related; my VM provisions fine).

What Should Happen?

should work

Error Messages/Logs

Steps to Reproduce

should work

Claude Model

None

Is this a regression?

Yes, this worked in a previous version

Last Working Version

No response

Claude Code Version

last

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

No response

extent analysis

TL;DR

The issue is likely related to the Claude Code process failing to create bridge sockets after 5 attempts, and a potential fix could involve investigating the network configuration or the Claude Code binary itself.

Guidance

  • Investigate the network configuration and ensure that the bridge sockets can be created successfully.
  • Check the Claude Code binary for any issues or errors that may be causing the failure to create bridge sockets.
  • Consider downgrading to a previous version of Claude Code that was known to work, if possible.
  • Review the logs and error messages to see if there are any additional clues about the cause of the failure.

Example

No code snippet is provided as the issue seems to be related to the Claude Code binary itself, and without more information, it's difficult to provide a specific code example.

Notes

The issue seems to be specific to the Claude Code process and the creation of bridge sockets. The fact that the VM boots and the guest connects successfully suggests that the issue is not related to the VM provisioning. The error message "Failed to create bridge sockets after 5 attempts" suggests that there may be a network configuration issue or an issue with the Claude Code binary itself.

Recommendation

Apply workaround: Investigate the network configuration and Claude Code binary to identify the root cause of the issue, as downgrading to a previous version may not be feasible or desirable.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

claude-code - 💡(How to fix) Fix [BUG]Cowork: guest Claude Code exits with "Failed to create bridge sockets after 5 attempts" (code 1, ~1s after spawn) [2 comments, 3 participants]