|
WebSocket event replay buffer for disconnect resilience
On reconnect to an active agent run the server now replays all events emitted since the turn started, then switches to live forwarding. This eliminates the gap where tool cards, thinking blocks and stream deltas were permanently lost after a network blip. Server (_AgentRun): - events: list[dict] buffers every serialised agent event - broadcast() serialises and appends before putting in subscriber queues - reconnect flow: subscribe → replay_count snapshot → stream_start → replay events[0:replay_count] → live _stream_to_client Client: - onStreamStart() removes the frozen ghost message instead of marking done=true, so replay cleanly rebuilds the message from scratch - replayMode flag suppresses animations during replay - onReplayStart/onReplayEnd handlers set/clear the flag and restore animate on the message once live events resume Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> |
|---|
|
|
| navi/api/websocket.py |
|---|
| webclient/dist/assets/index-B3zSedhg.js 0 → 100644 |
|---|
|
Not supported
|
| webclient/dist/assets/index-BMfdKPkG.js 100644 → 0 |
|---|
|
Not supported
|
| webclient/dist/assets/index-C0zKwfri.css 100644 → 0 |
|---|
| webclient/dist/assets/index-CzedwUs9.js 100644 → 0 |
|---|
|
Not supported
|
| webclient/dist/index.html |
|---|
| webclient/src/composables/useWebSocket.js |
|---|
| webclient/src/stores/chat.js |
|---|