Commit 4693292
committed
fix(chat,sdk): only treat channel records as replayed when the run is resuming
The previous commit took the replay window from the channel's tail so a stop that
no turn boundary covered could not be applied twice. On a first boot that is
wrong: nothing has been applied by anyone yet, so anything already on the channel
was treated as replayed and dropped.
That broke head starts. The client can signal a handover before the agent run has
booted, which is the whole point of the flow, and the signal was discarded as
already-applied. The agent then waited out its idle window and lost the warm
partial.
A replay window now only exists for a run that is resuming, which is either a run
whose predecessor left a turn boundary or one the wire marks as a continuation or
a retried attempt. A first boot has no window and applies what it finds.1 parent 89b5eb1 commit 4693292
1 file changed
Lines changed: 21 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1970 | 1970 | | |
1971 | 1971 | | |
1972 | 1972 | | |
1973 | | - | |
| 1973 | + | |
1974 | 1974 | | |
1975 | 1975 | | |
1976 | 1976 | | |
| |||
1986 | 1986 | | |
1987 | 1987 | | |
1988 | 1988 | | |
1989 | | - | |
1990 | | - | |
1991 | | - | |
1992 | | - | |
1993 | | - | |
1994 | | - | |
| 1989 | + | |
| 1990 | + | |
| 1991 | + | |
| 1992 | + | |
| 1993 | + | |
| 1994 | + | |
| 1995 | + | |
| 1996 | + | |
| 1997 | + | |
| 1998 | + | |
| 1999 | + | |
| 2000 | + | |
| 2001 | + | |
1995 | 2002 | | |
1996 | 2003 | | |
1997 | 2004 | | |
| |||
5590 | 5597 | | |
5591 | 5598 | | |
5592 | 5599 | | |
5593 | | - | |
| 5600 | + | |
| 5601 | + | |
| 5602 | + | |
5594 | 5603 | | |
5595 | 5604 | | |
5596 | 5605 | | |
| |||
5943 | 5952 | | |
5944 | 5953 | | |
5945 | 5954 | | |
| 5955 | + | |
5946 | 5956 | | |
5947 | 5957 | | |
5948 | 5958 | | |
| |||
9773 | 9783 | | |
9774 | 9784 | | |
9775 | 9785 | | |
9776 | | - | |
| 9786 | + | |
| 9787 | + | |
| 9788 | + | |
9777 | 9789 | | |
9778 | 9790 | | |
9779 | 9791 | | |
| |||
0 commit comments