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
chat: linkified paths in replies fail on click — ~ home paths not expanded, non-file text linkified as file reference #51872
In the desktop client, path-like text in agent replies (table cells, markdown link syntax) is rendered as clickable blue links. Clicking them is inconsistent: absolute paths open fine (including non-ASCII/Chinese directories), but home-relative ~ paths fail with "File not found", and non-file @ text (e.g. a skill-store coordinate) is linkified as a file reference and also fails.
The linkification heuristic and the click resolver disagree: the UI offers a click affordance for text it cannot resolve on click.
Environment
opencode version: CLI v2.0.15, background service /api/info reports 2.0.18 (mismatch)
OS: Windows_NT 10.0.26200 (Win32NT x64)
Terminal: desktop client; TERM=xterm-256color
Shell: C:\Windows\system32\cmd.exe
Install/channel: release (latest)
Active plugins: none found in config
Reproduction
Text of this form appears in an agent reply (table cell or markdown link):
C:\temp\preview-link-test.png — absolute, ASCII → click opens the file ✅
E:\下载\stitched-grid-5.png — absolute, Chinese path → click opens ✅
~/.skillhub/ — home-relative → click fails with "File not found"
@user_c3d829cb/img-stitch — skill-store coordinate (not a file) → click fails with "File not found"
Expected Behavior
Either: only linkify text the resolver can actually open (case 3 should resolve by expanding ~ to the user home, as permission rules do for read/external_directory resources), or: clicking an unresolvable path shows a non-error affordance / is not linkified at all (case 4).
Home expansion for ~ in click resolution is documented behavior elsewhere in V2 config ("OpenCode expands ~ and $HOME" for read/edit resources), so the chat click resolver is inconsistent with it.
Actual Behavior
Cases 1–2 open correctly; backslash and non-ASCII paths are handled fine.
Case 3: ~ is not expanded — resolved as a workspace-relative path → "File not found".
Case 4: @<something>/<something> is linkified as if it were a file reference → "File not found", even though it is a store coordinate, not a path.
Additional Context
Linkified contexts observed: table cells and explicit markdown link syntax [text](path). Plain body text and code blocks are NOT linkified — the heuristic is context-dependent and undocumented.
Thanks for the detailed report! I think this is a duplicate of #50390, which reports both problems: a ~-prefixed path in desktop chat fails with File not found while the absolute path works, and non-file text like owner/repo is linkified and fails the same way. A comment there confirms it still happens on 2.0.18 on Windows 10.0.26200, and there is an open PR (#50602) that addresses it.
Possible duplicates and related issues, ordered by likelihood:
Closing this as a duplicate of #50390, since there's been no reply saying how it differs. That issue covers both problems you saw: clicking a ~ path in desktop chat gives File not found, and text that isn't a file (like owner/repo or your @user/skill coordinate) gets turned into a clickable path link. Please follow #50390 and the open PR #50602 for updates. If your case turns out to be different, for example the @ problem tracked in #53502, reply here and we can reopen. Thanks again for the detailed report!
Activity
github-actions commentedon Sep 28, 2026
This issue might be a duplicate of existing issues. Please check:
~paths, and plain-textowner/repostrings are misdetected as clickable file references.write/edit) is treated as a clickable file path #51723: Slash-separated prose such aswrite/editis incorrectly rendered as a clickable file path.opencodejr commentedon Oct 28, 2026
Thanks for the detailed report! I think this is a duplicate of #50390, which reports both problems: a
~-prefixed path in desktop chat fails withFile not foundwhile the absolute path works, and non-file text likeowner/repois linkified and fails the same way. A comment there confirms it still happens on 2.0.18 on Windows 10.0.26200, and there is an open PR (#50602) that addresses it.Possible duplicates and related issues, ordered by likelihood:
~paths aren't expanded on click, and non-fileowner/repotext is linkified and fails@-mention links keep the literal@in the path and fail (related to your case 4)The bot will close this issue as a duplicate in 1 day unless you reply explaining how your problem is different.
opencodejr commentedon Oct 29, 2026
Closing this as a duplicate of #50390, since there's been no reply saying how it differs. That issue covers both problems you saw: clicking a
~path in desktop chat givesFile not found, and text that isn't a file (likeowner/repoor your@user/skillcoordinate) gets turned into a clickable path link. Please follow #50390 and the open PR #50602 for updates. If your case turns out to be different, for example the@problem tracked in #53502, reply here and we can reopen. Thanks again for the detailed report!