Description
After updating to the latest patch version on Windows Desktop, OpenCode started becoming unstable when I switch sessions or switch paths/workspaces while a prompt is actively running.
Important detail: this does not seem to happen when no agent/prompt is running. The issue is specifically triggered when work is still in progress and I switch context during that active work.
What happens:
- the in-flight prompt gets aborted
- the local server then dies / shuts off
- after restart, logs show what looks like an encoded workspace path being treated like a literal filesystem path
I have seen log behavior like:
- request paths that look like
/Qzpc.../session/...
- then a bootstrap path that looks like
C:\WINDOWS\system32\Qzpc...
The encoded segment appears to decode to the real workspace path, so it looks like OpenCode is incorrectly treating an encoded project path as a real directory after the context switch.
This seems easier to trigger in a parent workspace that is not itself a git repo, where child folders are separate git repos, but Desktop should still handle that safely.
This only started happening after updating to the latest patch version.
Plugins
None
OpenCode version
1.2.22
Steps to reproduce
- Open OpenCode Desktop on Windows.
- Open a workspace folder.
- Start a prompt / agent task in one session and wait until it is actively running or streaming.
- While that work is still in progress, switch to another session or switch paths/workspaces. Or view a subagent.
Observed:
- the active prompt is aborted
- the local server dies. This applies to both sidecar/persistent local server.
Not observed:
- if no prompt/agent is running, simply switching sessions/paths usually does not trigger the issue
Screenshot and/or share link
Redacted log excerpt showing session/path switch during active work on Windows Desktop
[1] Prompt is running normally
INFO 2026-03-09T02:18:17 service=llm providerID=openai modelID=gpt-5.4 sessionID=ses_[redacted] agent=build mode=primary stream
[2] While work is active, I switch sessions / paths
INFO 2026-03-04T08:18:20 service=server method=POST path=/session/ses_[redacted]/abort request
INFO 2026-03-04T08:18:20 service=session.prompt sessionID=ses_[redacted] cancel
ERROR 2026-03-04T08:18:20 service=session.processor error=The operation was aborted.
[3] Later, OpenCode starts using an encoded workspace path as part of the route
INFO 2026-03-04T09:23:59 service=server method=GET path=/QzpcVXNlcnNc[redacted]/session/ses_[redacted] request
INFO 2026-03-04T09:23:59 service=server status=completed duration=398 method=GET path=/QzpcVXNlcnNc[redacted]/session/ses_[redacted] request
INFO 2026-03-04T09:23:59 service=server global event disconnected
INFO 2026-03-04T09:23:59 service=server global event connected
[4] On the next startup / context handoff, OpenCode appears to treat that encoded path like a real filesystem path
INFO 2026-03-09T02:18:18 service=default directory=C:\WINDOWS\system32\QzpcVXNlcnNc[redacted] creating instance
INFO 2026-03-09T02:18:18 service=project directory=C:\WINDOWS\system32\QzpcVXNlcnNc[redacted] fromDirectory
INFO 2026-03-09T02:18:18 service=default directory=C:\WINDOWS\system32\QzpcVXNlcnNc[redacted] bootstrapping
Operating System
Windows 11 Pro
Terminal
Windows Terminal
Description
After updating to the latest patch version on Windows Desktop, OpenCode started becoming unstable when I switch sessions or switch paths/workspaces while a prompt is actively running.
Important detail: this does not seem to happen when no agent/prompt is running. The issue is specifically triggered when work is still in progress and I switch context during that active work.
What happens:
I have seen log behavior like:
/Qzpc.../session/...C:\WINDOWS\system32\Qzpc...The encoded segment appears to decode to the real workspace path, so it looks like OpenCode is incorrectly treating an encoded project path as a real directory after the context switch.
This seems easier to trigger in a parent workspace that is not itself a git repo, where child folders are separate git repos, but Desktop should still handle that safely.
This only started happening after updating to the latest patch version.
Plugins
None
OpenCode version
1.2.22
Steps to reproduce
Observed:
Not observed:
Screenshot and/or share link
Redacted log excerpt showing session/path switch during active work on Windows Desktop
[1] Prompt is running normally
INFO 2026-03-09T02:18:17 service=llm providerID=openai modelID=gpt-5.4 sessionID=ses_[redacted] agent=build mode=primary stream
[2] While work is active, I switch sessions / paths
INFO 2026-03-04T08:18:20 service=server method=POST path=/session/ses_[redacted]/abort request
INFO 2026-03-04T08:18:20 service=session.prompt sessionID=ses_[redacted] cancel
ERROR 2026-03-04T08:18:20 service=session.processor error=The operation was aborted.
[3] Later, OpenCode starts using an encoded workspace path as part of the route
INFO 2026-03-04T09:23:59 service=server method=GET path=/QzpcVXNlcnNc[redacted]/session/ses_[redacted] request
INFO 2026-03-04T09:23:59 service=server status=completed duration=398 method=GET path=/QzpcVXNlcnNc[redacted]/session/ses_[redacted] request
INFO 2026-03-04T09:23:59 service=server global event disconnected
INFO 2026-03-04T09:23:59 service=server global event connected
[4] On the next startup / context handoff, OpenCode appears to treat that encoded path like a real filesystem path
INFO 2026-03-09T02:18:18 service=default directory=C:\WINDOWS\system32\QzpcVXNlcnNc[redacted] creating instance
INFO 2026-03-09T02:18:18 service=project directory=C:\WINDOWS\system32\QzpcVXNlcnNc[redacted] fromDirectory
INFO 2026-03-09T02:18:18 service=default directory=C:\WINDOWS\system32\QzpcVXNlcnNc[redacted] bootstrapping
Operating System
Windows 11 Pro
Terminal
Windows Terminal