[Bug]: relative file chips resolve against the thread's project root, not the directory the agent worked in
Maintainer antworten meist innerhalb von 1 Tag
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Anfängerfreundlichkeit
- 48/100
- Issue-Typ
- Bug
- Klarheit
- Größtenteils klar
- Aktivitätsstatus
- Aktiv
- Tech-Stack
- typescript
Rechercherichtung
The issue identifies the affected area as apps/web chat file chips but does not name implementation files or tests. Start by tracing how inline file paths become chips and how their base directory is chosen, then inspect how thread activity records working directories. Done when a real relative path from another checkout opens from the correct root, with a defined fallback when that root is unavailable.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
before submitting
- I searched existing issues and did not find a duplicate.
- I included enough detail to reproduce or investigate the problem.
area
apps/web (chat file chips)
what happens
an assistant message lists files with repo-relative paths in inline code, e.g. docs/guides/new_guide.md.
t3 renders a chip, but resolves it against the thread's project root.
the agent did its work in a different checkout (a worktree of another repo), so the chip opens "the file could not be accessed or read" even though the file exists and the path is correct relative to where the agent was working.
steps to reproduce
-
create a thread in project
repo-a(root/Users/me/devel/repo-a). in my case the thread was spawned through the t3 mcp orchestration tools, so it has noworktreePathand no branch. -
in that thread, have the agent
cdinto a worktree of a different repo, e.g./Users/me/devel/worktrees/repo-b-feature, make changes there and open a pr. -
the agent summarises the pr with repo-relative paths:
- `docs/guides/new_guide.md` is the new guide. - `server/config.yaml` and `config.test.yaml` each gain two lines. -
click a chip.
expected
the chip opens /Users/me/devel/worktrees/repo-b-feature/docs/guides/new_guide.md, or at least does not pretend to be a working link.
actual
the chip opens /Users/me/devel/repo-a/docs/guides/new_guide.md, which does not exist, and shows the "could not be accessed" panel.
a bare filename like config.test.yaml fails the same way.
why this is different from the existing issues
- #29421 / #30021 / #29657 deal with paths that do not exist anywhere (example paths in prose). #30021 (closed unmerged) would have rendered missing paths as plain code, #29657 keeps the full label but leaves them clickable. here the path is real, only the resolution root is wrong, so neither direction makes the chip work.
- the second comment on #29421 is the same shape (a correct path for another workspace), but framed as "should fall back to plain code".
- #30285 is related: pr descriptions turn the author's paths into links that open on the viewer's machine. same root cause, a path is resolved against the wrong base.
possible directions
- resolve relative chips against the agent's working directory at the time of the message (the cwd of the session, or the last
cd/ tool-call cwd t3 already sees in the activity log), falling back to the project root. - when the path does not exist under the project root, try the worktrees / checkouts the thread touched (its linked prs' head checkouts,
worktreePath), and only then fall back to plain code as in #30021. - for mcp-spawned threads that work in another repo, let the agent set or update the thread's working root, so chips and the diff view follow it.
workaround
instruct the agent (CLAUDE.md / AGENTS.md) to always write absolute paths in chips. this works, but agents drop it easily when listing files changed in a pr, because they naturally think in repo-relative terms there.
environment
t3 code desktop 0.1.9-nightly.20261110.4478, macos 26 (darwin 25.6.0), claude agent provider.
- Vorherrschende Sprache
- TypeScript
- Sterne
- 24.8k
- Forks
- 6.4k
- Ø Merge
- 4 Std. 16 Min.
- Gemergte PRs (30 T.)
- 352
Entwicklungsumgebung
Startet den Dev-Container des Projekts im Browser, mit Ihrem eigenen GitHub-Konto.
- Kein Dockerfile und keine Docker-Compose-Datei
- Hat eine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus pingdotgg/t3code
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 84/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 67/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 82/100
Maintainer antworten meist innerhalb von 1 Tag
Alle Issues in pingdotgg/t3code
Ähnliche Issues
-
idea-scout idea:453
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 83/100
jeanibarz/agent-notebook#453 ·
Maintainer antworten meist innerhalb von 1 Tag
-
level/task
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 95/100
wazuh/wazuh-dashboard-plugins#9642 ·
Maintainer antworten meist innerhalb von 1 Tag
-
bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 91/100
unicef/adt-studio#1112 ·
Maintainer antworten meist innerhalb von 2 Tagen
-
feature request good first issue
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 88/100
TabularisDB/tabularis#1513 ·
Maintainer antworten meist innerhalb von 2 Tagen
-
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 75/100