anomalyco / anomalyco/opencode
Deleting a session is slow/hangs, leaves ghost sessions, and can freeze the whole app
Open
@Hona is already working on this.
Since Aug 14, 2026.
- Dominant language
- TypeScript
- Stars
- 209k
- Forks
- 27.5k
- PR merge metrics
- PR metrics pending
Description
Description
Deleting a session in the desktop app is very slow, often hangs, and can freeze the
entire app — with no error output in the logs. All three symptoms below appear to share
one root cause: session removal (removing share) gets stuck.
Observed symptoms (opencode 1.18.18 desktop, Windows 10):
- Deletion is slow / hangs. A single deletion takes 10–30+ seconds; the UI becomes
unresponsive. In the log (%USERPROFILE%\.local\share\opencode\log\opencode.log)
consecutiveremoving shareentries during a bulk delete of ~40 sessions show gaps
of 6–28 seconds each. - Ghost sessions. If the app is killed during a deletion, the deleted session still
appears on the home screen after restart. Clicking it opens the chat and immediately
errors instead of loading. The interrupted removal apparently leaves the session in
the local DB. - Full freeze, silent. The app sometimes stops logging entirely and must be
force-killed. Three incidents today (local time):- 11:50 → 12:11 (21.8 min of silence) right after the bulk deletion above;
- 16:02 → 16:17 (14.6 min, no graceful shutdown) right after opening/closing a terminal
(creating sessionpty →removing session); - 16:26:31 (
exiting loop) → 16:27:54 (removing share) → hung until killed at
~16:28:25.
A normal shutdown logsdisposing all instances; in the 16:02 incident that never
appeared. Nolevel=ERROR, no stack trace, no abort — pure silent hang.
Plugins
None (only the default @opencode-ai/plugin dependency in ~/.config/opencode/package.json; no custom plugins or config)
OpenCode version
1.18.18 (desktop app)
Steps to reproduce
- Delete a session from the home screen (single or multiple)
- Observe that deletion takes tens of seconds or hangs the UI
- If the app freezes, force-kill it and restart
- The "deleted" session still appears on the home screen
- Click that session → an error occurs instead of loading the chat
- Optionally: open and close a terminal to reproduce the silent freeze
Screenshot and/or share link
No response
Operating System
Win11
Terminal
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.