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
Data is stored in the wrong session when multiple sessions are running #20552
I had a session running in Build mode and went and opened a new session in Plan mode. As they were running, data from the Build session started showing up in the Plan session.
You can see that my Plan session (consisting of only 1 prompt) shows that it edited files:
The review tab for both sessions displays identical changes, in both "Last Turn" and "Session" changes modes.
However, this isn't isolated to a UI problem. I used the event stream to confirm that the PATCH parts were in fact getting sent to messages in the Plan session. I then double checked the opencode.db sqlite file directly and confirmed that the Plan session did in fact have stored patch parts.
Plan Session ID: ses_2b54c85c5ffejvxUwZT2t1ffuc
Patch parts:
Messages with the Patch parts + the message from parentID showing mode is set to plan
I don't see any "read" nor "write" tool parts in the Plan session corresponding to the files it says it patched so it might be isolated to the PATCH parts.
I don't know if those parts are contributing to the Message's token counts and inflating the stats since the Messages do also have real parts in them alongside the incorrect PATCH parts.
Plugins
No response
OpenCode version
v1.3.13
Steps to reproduce
Not sure if this is relevant, but I'm running opencode web in the terminal and then having OpenCode Desktop connect to that port. Then just run 2 sessions in 1 project in the same workspace.
Activity
fix(session): prevent cross-session patch contamination (anomalyco#20552
github-actions commentedon Jul 3, 2026
To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.