Skip to content

[Bug] Edit/Write operations store full file content per edit, causing transcript bloat and resume hang on large files #78592

Description

@binaryplates

Bug Description
Title: Edit/Write stores full file content per edit → multi-MB files bloat transcript and freeze "Resuming conversation…"

What happens: Each Edit/Write call records the entire before+after file content in the transcript's toolUseResult field. Editing a 5.4 MB file writes ~5.4 MB per edit regardless of change size. Seven edits produced an 80 MB .jsonl; resume then hangs on "Resuming conversation…" indefinitely.

Repro: Edit a >5 MB text file ~7 times in one session → quit → resume. It never loads.

Impact: Session appears unrecoverable. Manual fix required: trim oversized toolUseResult lines from the .jsonl (80 MB → 965 KB restored resume).

Comparison: Codex edits the same file 150× with no freeze — its apply_patch records only the diff hunk (max transcript line 331 KB vs. Claude Code's ~11.8 MB/line).

Suggested fix: Store a diff/patch in toolUseResult for large files instead of full snapshots, or cap/externalize snapshots above a size threshold.

Environment Info

  • Platform: linux
  • Terminal: vte-based
  • Version: 2.1.211
  • Feedback ID: c86c2dbf-a21a-463e-addc-59ff3173c4c6

Errors

[]

Activity

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

    duplicateThis issue or pull request already exists

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions