fix(session): pin the token offset when only the display window advances

Commit

peyton-alt20h ago

The turn-end advances after a mid-turn commit move CheckpointTranscriptStart without storing tokens. An unset TokenTranscriptStart falls back to CheckpointTranscriptStart, so it would follow the display window forward and skip that turn's tail tokens. AdvanceDisplayWindow pins the token offset before moving the window; both turn-end sites use it.

Co-Authored-By: Claude Opus 5.5 noreply@anthropic.com Entire-Checkpoint: 01M47MXV4A361ASRFC7NM860TX

Checkpoints

Fix Checkpoint Token Double Count Bug

Claude CodeOpus 5.5
View session
Checkpoint 1