[Bug] Linux: _globalLastSpawn is not defined — Workspace fails to start
Resolved 💬 1 comment Opened May 27, 2026 by dirkweisbach1981 Closed Jun 27, 2026
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?
What's wrong
When opening Claude Desktop on Linux and navigating to the Workspace/Cowork tab, the workspace fails to start immediately with the error:
Fehler beim Starten von Claudes Arbeitsbereich — _globalLastSpawn is not defined
(Error starting Claude's workspace — _globalLastSpawn is not defined)
The built-in "Reinstall workspace" option does not resolve the issue. Restarting the app or the computer also has no effect.
What Should Happen?
2026-05-27 19:37:39 [error] Failed to run onQuitCleanup(cowork-vm-shutdown): ReferenceError: _globalLastSpawn is not defined
Error Messages/Logs
bash# Install asar tool
npm install -g @electron/asar
# Extract
asar extract /usr/lib/claude-desktop/node_modules/electron/dist/resources/app.asar /tmp/claude-asar
# Add the missing declaration
sed -i '1s/^/var _globalLastSpawn;\n/' /tmp/claude-asar/.vite/build/index.js
# Backup original
sudo cp /usr/lib/claude-desktop/node_modules/electron/dist/resources/app.asar \
/usr/lib/claude-desktop/node_modules/electron/dist/resources/app.asar.backup
# Repack and replace
asar pack /tmp/claude-asar /tmp/app-patched.asar
sudo cp /tmp/app-patched.asar \
/usr/lib/claude-desktop/node_modules/electron/dist/resources/app.asar
After restarting Claude Desktop, the workspace starts successfully.
Steps to Reproduce
- Install Claude Desktop on Linux (e.g. via the claude-desktop-debian repackage)
- Open Claude Desktop
- Open or start any chat that uses the Workspace (Cowork/bash environment)
- Observe the error banner immediately
Claude Model
Sonnet (default)
Is this a regression?
Yes, this worked in a previous version
Last Working Version
_No response_
Claude Code Version
1.9255.0 (a22af1)
Platform
Anthropic API
Operating System
Ubuntu/Debian Linux
Terminal/Shell
Other
Additional Information
This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗