fix(session): retain fork tail until the first inbox change
This commit is contained in:
1 parent
896a6c3e47
commit
0f8552df7f
11 files changed
+55
-34
No files matched your search
@@ -240,7 +240,12 @@ export class SessionCommandController {
|
||||
{ sessionId: request.sessionId },
|
||||
)
|
||||
}
|
||||
const cut = SessionLogOffset(boundary.seq + 1)
|
||||
let cut = SessionLogOffset(boundary.seq + 1)
|
||||
while (cut < source.events.length
|
||||
&& source.events[cut]?.type !== 'turn/start'
|
||||
&& source.events[cut]?.type !== 'agent/inbox/spliced') {
|
||||
cut = SessionLogOffset(cut + 1)
|
||||
}
|
||||
let workspace: Workspace | undefined
|
||||
try {
|
||||
workspace = await this.forkWorkspace(source.header)
|
||||
|
||||
Reference in new issue
Block a user