What
Claude Code saves each conversation to a transcript file, one record per line, and reads it back when you resume. When a long conversation is compacted (older messages are summarised to save space), the file holds a marker at that point. The way Claude Code reads these files has been reworked:
- After a compaction marker, later lines are no longer fully processed up front. Claude Code notes where they are and reads them only when needed to rebuild the messages kept across compaction, looking back at most 2048 lines.
- The most recent prompt record is now found by checking the start of each line and re-reading from the end of the file, to recover the newest point in the conversation.
- Neighbouring lines are read in blocks of up to 1 MiB and processed together.
- Lines that cannot be read, for example because a write was cut off, are counted, skipped and noted in the debug log. Before, they disappeared without a trace.
- An error while closing the file no longer hides an earlier error that was already being reported.
Why
Resuming long sessions that have been compacted many times should be quicker. If part of a transcript is damaged, the debug log now shows that lines were skipped, which makes problems with a saved session easier to track down.
Something disagreesSomething we can check disagrees with this entry, or the writer said they could not settle it.
The writer flagged doubt
What condition turns off the new deferred reading after a compaction marker is not known.