You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
bug(desktop): orphaned opencode-cli processes on Linux after app exit #11959
On Linux, the desktop app leaves opencode-cli sidecar processes running after the UI exits or crashes. This accumulates orphaned processes and memory usage. Windows has job objects; Linux had no equivalent cleanup.
Repro
Launch the desktop app.
Open a project / start the local sidecar server.
Close the app or crash/kill the UI.
ps still shows opencode / opencode-cli processes running.
Fix (already implemented in branch)
Add Linux process group management with PR_SET_PDEATHSIG and setsid for child cleanup.
Track PIDs and kill process groups on exit.
Spawn sidecar on Linux with pre_exec calling configure_child_process.
Add libc dependency for prctl/setsid.
Commit: 4bd93a5a5 (fix(desktop): ensure child processes are killed on Linux when app exits).
Verification
Closing the app now sends SIGTERM to the child and its process group; no orphan processes remain.
These issues all describe similar orphaned process problems. The Linux-specific solution you've implemented (using PR_SET_PDEATHSIG and setsid) may help resolve multiple related issues beyond just the desktop app.
Feel free to ignore if this specific Linux desktop app scenario is distinct from these other cases.
Activity
github-actions commentedon Feb 3, 2026
This issue might be a duplicate of existing issues. Please check:
These issues all describe similar orphaned process problems. The Linux-specific solution you've implemented (using PR_SET_PDEATHSIG and setsid) may help resolve multiple related issues beyond just the desktop app.
Feel free to ignore if this specific Linux desktop app scenario is distinct from these other cases.
github-actions commentedon Apr 5, 2026
To stay organized issues are automatically closed after 90 days of no activity. If the issue is still relevant please open a new one.