Clicking a file reference an agent wrote, like ChatView.tsx:3301, fails:
Failed to read workspace file 'ChatView.tsx' in '/Users/me/dev/t3code'.
The :line suffix is what makes the span a link — a bare ChatView.tsx deliberately isn't one. But the filename alone doesn't say where the file is, so resolveMarkdownFileLinkTarget joins it to the workspace root, and that's rarely where it lives. Agents write references in this shape constantly, so a lot of these links are dead.
To reproduce: post a message containing `SomeFile.tsx:42` in a repo where that file isn't at the root, and click the chip.
Clicking a file reference an agent wrote, like
ChatView.tsx:3301, fails:The
:linesuffix is what makes the span a link — a bareChatView.tsxdeliberately isn't one. But the filename alone doesn't say where the file is, soresolveMarkdownFileLinkTargetjoins it to the workspace root, and that's rarely where it lives. Agents write references in this shape constantly, so a lot of these links are dead.To reproduce: post a message containing
`SomeFile.tsx:42`in a repo where that file isn't at the root, and click the chip.