Description
On CachyOS (Arch-based Linux), OpenCode desktop fails to open the current workspace directory in both Sublime Text and Zed from the session header's "Open with ..." menu. The app shows Request failed and the backend error is Failed to open path: No such file or directory (os error 2).
This does not look like a missing project directory. It looks like editor resolution on Linux:
command -v zed -> ~/.local/bin/zed
command -v subl -> /usr/bin/subl
command -v sublime_text -> not found
Relevant implementation details I traced while debugging:
packages/app/src/components/session/session-header.tsx
- Linux app map uses
openWith: "zed" for Zed
- Linux app map uses
openWith: "Sublime Text" for Sublime Text
packages/desktop/src-tauri/src/lib.rs
check_linux_app currently returns true unconditionally, so unavailable or misresolved apps are still shown
open_path forwards the app name directly to tauri_plugin_opener::open_path
- In
tauri-plugin-opener, when an app is provided it ultimately calls open::with_detached(path, program); it doesn't prevalidate the path first, so os error 2 appears to be the program lookup failing rather than the workspace path missing
Possibly there are two issues here:
- Sublime Text is using a display name instead of the Linux executable (
subl)
- Zed may fail when OpenCode desktop does not inherit a PATH containing
~/.local/bin
Steps to reproduce
- On CachyOS/Arch Linux, install Zed and Sublime Text
- Open OpenCode desktop
- Open any session/workspace
- Use the session header and choose "Open with Zed" or "Open with Sublime Text"
Expected behavior
The workspace directory opens in the selected editor.
Actual behavior
OpenCode shows Request failed and Failed to open path: No such file or directory (os error 2).
Plugins
Unknown / not relevant
OpenCode version
1.3.9
Screenshot and/or share link
None
Operating System
CachyOS (Arch-based Linux)
Terminal
bash
Description
On CachyOS (Arch-based Linux), OpenCode desktop fails to open the current workspace directory in both Sublime Text and Zed from the session header's "Open with ..." menu. The app shows
Request failedand the backend error isFailed to open path: No such file or directory (os error 2).This does not look like a missing project directory. It looks like editor resolution on Linux:
command -v zed->~/.local/bin/zedcommand -v subl->/usr/bin/sublcommand -v sublime_text-> not foundRelevant implementation details I traced while debugging:
packages/app/src/components/session/session-header.tsxopenWith: "zed"for ZedopenWith: "Sublime Text"for Sublime Textpackages/desktop/src-tauri/src/lib.rscheck_linux_appcurrently returnstrueunconditionally, so unavailable or misresolved apps are still shownopen_pathforwards the app name directly totauri_plugin_opener::open_pathtauri-plugin-opener, when an app is provided it ultimately callsopen::with_detached(path, program); it doesn't prevalidate the path first, soos error 2appears to be the program lookup failing rather than the workspace path missingPossibly there are two issues here:
subl)~/.local/binSteps to reproduce
Expected behavior
The workspace directory opens in the selected editor.
Actual behavior
OpenCode shows
Request failedandFailed to open path: No such file or directory (os error 2).Plugins
Unknown / not relevant
OpenCode version
1.3.9
Screenshot and/or share link
None
Operating System
CachyOS (Arch-based Linux)
Terminal
bash