GeezerVison is showing github.com — [Bug] Windows paths with different separators (backslash vs forward slash) treated as different directories in Web UI · Issue #12940 · anomalyco/opencode
[Bug] Windows paths with different separators (backslash vs forward slash) treated as different directories in Web UI #12940
Description
Description
On Windows, the same directory is treated as different directories depending on the path separator used, causing conversations to not be shared/accessible between them.
Example
- Actual Windows path: "E:\AA\BB"
- When opened via Web UI search: "E:/AA/BB"
These two representations point to the same physical directory, but they are treated as separate directories in the Web UI. As a result:
- Conversations started in one path format cannot be accessed when the directory is opened with the other format
- This creates duplicate/inconsistent conversation history
Expected Behavior
Paths should be normalized (converting backslashes to forward slashes or vice versa) before being used as directory identifiers, so that and are recognized as the same directory.
Environment
- OS: Windows
- OpenCode version: (latest)
- Web UI accessed via browser
Related Issues
Possibly related to #1374 (Windows path separator issues)
Steps to Reproduce
- On Windows, navigate to a project directory (e.g., )
- Open OpenCode Web UI
- Start a conversation
- Use Web UI search to open the same directory (which may show as )
- Observe that the previous conversation is not accessible
Additional Context
This is likely a path normalization issue where Windows backslash paths () are not being normalized to match forward slash paths () when used as directory identifiers in the Web UI session management.
Activity
github-actions commented on Feb 10, 2026
This issue might be a duplicate of existing issues. Please check:
EgilSandfeld commented on Feb 21, 2026
I can confirm this issue on Windows, and I have additional repro details (posted in #14570) that seem related:
Additional findings
- Drive-letter case mismatch also breaks session visibility
/session?directory=b:/dev/DRE/dre4 returns sessions
/session?directory=B:/dev/DRE/dre4 can return 0
- So this is not only slash mismatch (
\ vs /), but also case-sensitive directory key matching.
- Duplicate workspace entry for the same worktree
feature/loc-turkish appears twice in sidebar.
- One entry has sessions, the other is empty.
- Looks like path variants such as
C:/.../crisp-planet and C:\...\crisp-planet are treated as separate workspaces.
- Global project edge case
- For non-git/global context (
project_id=global, worktree /), /session?directory=b:/dev/Other/OpenCode-Playground returns rows, but sidebar can remain empty.
Suggested fix
Normalize Windows paths before using them as identifiers for:
- project/workspace resolution
- session filtering
- workspace dedupe
Normalization should include:
- slash style (
\ vs /)
- drive-letter case (
B: vs b:)
- case-insensitive comparisons on Windows
github-actions commented on Apr 23, 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.
Metadata
Metadata
Development
No branches or pull requestsIssue actions