SendUserFile renders relative path chip in terminal sessions — file not locatable, no content shown
Status Open
Maintainer reply None cached
Activity 1 comment · opened Jul 27, 2026
Problem
In a pure terminal/TUI session (this happened in a background job session), SendUserFile renders as a compact chip in the transcript:
[file] .agent-runs/<run-id>/BEFORE_AFTER.md (81.2KB)
Two things make this unusable in a terminal context:
- The path shown is whatever string was passed to the tool, not the resolved path. The agent called
SendUserFilewith a path relative to the session cwd. The chip displays that relative string verbatim. The user's shell was at~, socat .agent-runs/<run-id>/BEFORE_AFTER.mdreturnedNo such file or directoryand there was no way to tell from the transcript where the file actually is. The harness knows the session cwd and could resolve it.
- The chip has no affordance to open or preview the content, and nothing is visibly "sent" anywhere. In the desktop/IDE surfaces the chip is at least a UI element; in a terminal session it is inert text. The net effect is that the feature reads as broken — the agent reports success, the user sees a filename they cannot locate and cannot read.
Repro
- Start a Claude Code CLI session in a terminal (reproduced in a background job session on Linux/WSL2).
- Have the agent call
SendUserFilewith a relative path, e.g..agent-runs/<run-id>/BEFORE_AFTER.md. - Transcript shows
[file] .agent-runs/<run-id>/BEFORE_AFTER.md (81.2KB). - From a different cwd (e.g.
~),cat .agent-runs/<run-id>/BEFORE_AFTER.md→No such file or directory. - No preview, no inline content, no way to open the file from the chip.
Expected
- The chip should always display the resolved absolute path, regardless of what was passed to the tool. Path resolution is unambiguous server-side (the harness owns the cwd), so a relative-path argument should never surface to the user as a relative path.
- In terminal sessions, delivered files should be viewable: either inline the content (at least for text files, possibly truncated with the absolute path for the rest), or emit a clearly labelled, copy-pasteable absolute path so
cat/$EDITORworks in one step. - Ideally, if a terminal session genuinely cannot deliver a file anywhere the user can consume it, the tool result should say so rather than reporting plain success.
Related (not duplicates)
- #58318 — VS Code extension chip should show full path (closed/stale, different surface).
- #78649 — desktop/macOS open + copy-path affordances for delivered files (desktop UI, image-review focused).
This report is specifically about the terminal/TUI surface and about the displayed path being the unresolved argument rather than the absolute path.
Environment
- Claude Code CLI on Linux (WSL2)
- Terminal session, running as a background job (no desktop/IDE surface attached)
This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗