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
Log File Deleted When Multiple IDE Instances Are Attached to OpenCode Server #4999
OpenCode v1.0.128 installed via curl script in a containerized setup.
Server running locally using opencode serve.
Steps to Reproduce
Start the OpenCode server with opencode serve.
Attach the first IDE instance using opencode attach, which creates a log file.
Attach a second IDE instance using opencode attach.
Confirm server container instance ID has not changed.
Expected Behavior
Each IDE instance should maintain its own log file, or separate logs should be preserved for concurrent sessions without deletion or overwriting.
Actual Behavior
Upon attaching a new IDE instance, the previous log file is deleted, and a new log file is created with a timestamp corresponding to the most recent attachment. As a result, with multiple (e.g., two) IDE instances open, only one log file exists, reflecting the latest launch time. This leads to loss of logs from earlier instances.
Impact
This behavior hinders debugging and monitoring of multiple concurrent IDE sessions, as historical logs are not retained.
Suggested Resolution
Consider implementing server log file AND per-attach-instance log files (e.g., differentiated by session ID or timestamp) or appending to existing logs instead of overwriting.
While not exact duplicates, both issues deal with serve mode logging problems affecting multiple sessions. Feel free to check that issue to see if there's any shared context.
Hmmm, I see the same behavior when i switch to just using the TUI (no opencode serve then opencode attach).
However in the TUI scenario the logs contain much more data - in the serve-attach scenario there was generally only one line in the file.
In the spirit of calling out excellent engineering and design....
I've found that the Pi Coding Agent is more robust and, for me has none of the issues that I've encountered in OC, or has an elegant way to resolve them.... I'm dropping out of OC issues:
Activity
github-actions commentedon Dec 2, 2025
This issue might be related to:
While not exact duplicates, both issues deal with serve mode logging problems affecting multiple sessions. Feel free to check that issue to see if there's any shared context.
taqtiqa-mark commentedon Dec 2, 2025
No #1649 is not relevant. Here the whole log file for another running OC client is deleted.
taqtiqa-mark commentedon Dec 3, 2025
Hmmm, I see the same behavior when i switch to just using the TUI (no
opencode servethenopencode attach).However in the TUI scenario the logs contain much more data - in the serve-attach scenario there was generally only one line in the file.
taqtiqa-mark commentedon Feb 6, 2026
In the spirit of calling out excellent engineering and design....
I've found that the Pi Coding Agent is more robust and, for me has none of the issues that I've encountered in OC, or has an elegant way to resolve them.... I'm dropping out of OC issues: