Root cause: On macOS, GUI applications don't inherit shell profile modifications (.zshrc, .bashrc). When OpenWork spawns the opencode engine, the PATH doesn't include paths like
  /opt/homebrew/bin where Homebrew-installed tools like npx reside.

  The fix (packages/desktop/src-tauri/src/paths.rs): Added a common_tool_paths() function that returns typical locations where user-installed tools are found:
  - macOS: /opt/homebrew/bin, /usr/local/bin, ~/.nvm/current/bin, ~/.volta/bin, ~/.bun/bin, ~/.cargo/bin, etc.
  - Linux: Similar paths adapted for Linux conventions
  - Windows: volta, pnpm, cargo, npm global paths

  These paths are now prepended to the PATH environment variable when spawning processes.

  To test the fix: Build and run the app, then try enabling your Playwright MCP server - it should now find npx correctly without needing to specify the full path.
This commit is contained in:
Aayush Prajapati
2026-02-15 01:53:50 +05:30
committed by GitHub
parent 799bc194bd
commit 4cabebd2a9
2 changed files with 107 additions and 1 deletions

12
package-lock.json generated Normal file
View File

@@ -0,0 +1,12 @@
{
"name": "@different-ai/openwork-workspace",
"version": "0.0.0",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "@different-ai/openwork-workspace",
"version": "0.0.0"
}
}
}