t3code icon indicating copy to clipboard operation
t3code copied to clipboard

[Bug]: A file name with a backslash shows under a folder that does not exist in the Changes card

Open only21mil opened this issue 2 weeks ago • 0 comments

Before submitting

  • [x] I searched existing issues and did not find a duplicate.
  • [x] I included enough detail to reproduce or investigate the problem.

Area

apps/web

Steps to reproduce

  1. In a Git repository on Linux or macOS, commit two files: back\slash.txt (a backslash in the file name) and back/slash.txt.
  2. In one turn, add one line to back\slash.txt and two lines to back/slash.txt.
  3. When the turn ends, expand the Changes card under the reply and click the +1 row.

Expected behavior

back\slash.txt is its own row next to the back folder, and clicking it opens the back\slash.txt diff.

Actual behavior

The card shows both files as slash.txt under a single back folder (+3). Clicking the +1 row opens the back/slash.txt diff, and back\slash.txt stays collapsed in the diff panel, so I cannot reach its change from the card. The browser console also logs a duplicate React key for file:back/slash.txt.

Impact

Minor bug or occasional failure

Version or commit

main, commit b68aedf

Environment

Server built from source on macOS, web client in Chromium on Linux, Replay (dev) provider. I made the two edits while the turn waited for approval.

Logs or stack traces

Encountered two children with the same key, `%s`. Keys should be unique so that components maintain their identity across updates. ... file:back/slash.txt

Screenshots, recordings, or supporting files

main b68aedf: both files show as slash.txt under one back folder (+3) in the Changes card main b68aedf: both files show as slash.txt under one back folder (+3) in the Changes card

Workaround

Open the diff panel and expand back\slash.txt there.

A fix is in #23167.

only21mil avatar Nov 12 '26 09:11 only21mil