This repository has been archived on 2026-10-08 . You can view files and clone it. You cannot open issues or pull requests or push a commit.
5a47f6fbf6ee056121fd837f6cf129afbc50a671
A resumed session opened on a blank pane: the agent's conversation came back, the terminal history the operator was reading did not. Each PTY bridge's replay ring is now mirrored to `<state_dir>/scrollback/<id>.bin` and handed to the new bridge on resume, and on the recovery pass that re-adopts a session tmux still holds — that one lost its ring with the previous daemon too. Restored bytes go out ahead of the live ones, and are dropped once the ring holds a full budget of new output of its own. Flushed every 10 seconds by the liveness watcher, and once more when a bridge is sealed on exit. The timer is the part that matters: a host reboot runs no exit path at all, so a scrollback written only on a clean shutdown is missing in exactly the case this exists for. Ten seconds bounds the loss to the last few lines — this is visual continuity, not state — and costs at most one file write per active session per tick, since a session whose bridge has read nothing since the last flush is skipped. The file is capped at the existing `pty_replay_bytes` budget rather than a second one, is deleted on kill and when recovery prunes a sidecar, and a missing, unreadable or oversized one degrades to an empty pane instead of failing the resume. Closes #171 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Description
No description provided
13 MiB
Languages
Rust
62.2%
TypeScript
22.6%
Kotlin
9.7%
CSS
4.4%
Nix
0.5%
Other
0.5%