Skip to content

Turn file-change summary misses shell edits; offer a git-diff source like Changes #6809

Description

@brzvsk

The workflow

I let agents edit code and then read the turn's file-change summary in the timeline ("Edited N files" with per-file diffs) to check what changed. For most of my turns it does not appear.

What happens today

The summary is built only from provider fileChange items (case "file-change" in timeline-view.ts, phrase in fileChangeSummaryPhrase). Edits made through the shell are commandExecution items, so the turn shows "Ran N commands" with the script text and no diff.

Agents now make most edits through the shell. Claude Code injects this into its system prompt in bypass and auto mode (flag tengu_thrifty_sonic, present in 2.1.302):

While bypass permissions mode is active: … make small, mechanical file changes with sed, heredocs, or short scripts instead of the dedicated Read, Edit, or Write tools.

Related reports: anthropics/claude-code#87971, anthropics/claude-code#92271. Shell edits also tend to be cheaper and work well, so asking agents to switch back to Edit is not the fix.

Measured on my bb install, 15 days of events rows (item/completed, fileChange versus commandExecution commands classified by regex: python3 - <<EOF with write_text/open(...,'w'), sed -i, cat > file <<EOF; writes to /tmp and thread storage excluded):

provider / model threads edits via fileChange via shell
claude-code / claude-opus-5-5 111 1477 16% 84%
codex / gpt-6-astra 30 168 21% 79%
acp-opencode / deepseek-v4.1-flash 75 2681 54% 46%

Cross-checked against Claude Code's own session logs: Edit/Write 14%, Bash edits 86%, Edit errors 16 of 472, so this is not a fallback after failed Edit calls.

The git-based Changes panel does show these files (selectWorkspaceChangedFilesSections), but only until they are committed. When an agent commits and pushes on the default branch, both Uncommitted and Committed are empty, so the turn's changes are visible nowhere as a diff.

What you would expect

An option (setting or toggle on the summary) to build the turn's file-change summary from git: workspace diff between turn start and turn end, rendered with the same diff card as Changes. Shell edits, fileChange edits and generated files would all show up, whatever tool wrote them.

One possible shape:

  • At turn start the host snapshots the working tree without touching the user's index (temporary GIT_INDEX_FILE + git add -A + git write-tree). At turn end it diffs that tree against the working tree and HEAD, so changes committed during the turn still count.
  • Codex already sends turn/diff/updated with a unified diff for the turn. bb currently drops it at ingest (events.ts). It could be the first source for Codex threads.

Context and alternatives

  • Open questions: in a shared project checkout another thread may change files during the same turn, so the summary would be labelled "workspace changes during this turn" rather than strictly "this agent's changes". Files outside the environment's repository (cd ../other-repo && …) would stay invisible.
  • Workarounds today: open each commit from the Commits section, or read the shell scripts in the timeline.
  • Searched open and closed issues for "turn diff", "turn/diff/updated", "file changes bash", "Edited files summary"; nothing matching.
  • bb 0.48.1, macOS, Claude Code 2.1.302. Code cited at 916d684ac23d0b0de82c09cfc7553a50287d2188.

AGENT GENERATED

Activity

  1. added
    threads
    workspaces
    on Nov 2, 2026
  2. bb-slop-cop commented on Nov 2, 2026

    @bb-slop-cop
    Contributor

    🚨 SLOP COP 🚨 · new-issue-autopilot

    Applied Type: Feature, Priority: Medium, Effort: High, and labels threads, workspaces. All classifications were missing; no existing values were replaced. Verified the final Type and all applied values.

    The current timeline counts provider-reported file changes separately from commands. A durable, tool-independent workspace diff per turn adds new functionality rather than repairing an existing git-backed summary. Medium priority reflects the review gap with commit/script workarounds; High effort reflects snapshot lifecycle, persistence, and shared-checkout attribution decisions.

    No reproduction report or pull request: the final Type is Feature, so this rule stops after triage.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    threadsworkspaces

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions