Gateway: bound agent run sequence tracking

This commit is contained in:
Vignesh Natarajan
2026-02-14 17:50:49 -08:00
parent 451deb066f
commit fc8f59261a
5 changed files with 68 additions and 1 deletions

View File

@@ -88,8 +88,12 @@ export function abortChatRunById(
ops.chatAbortControllers.delete(runId);
ops.chatRunBuffers.delete(runId);
ops.chatDeltaSentAt.delete(runId);
ops.removeChatRun(runId, runId, sessionKey);
const removed = ops.removeChatRun(runId, runId, sessionKey);
broadcastChatAborted(ops, { runId, sessionKey, stopReason });
ops.agentRunSeq.delete(runId);
if (removed?.clientRunId) {
ops.agentRunSeq.delete(removed.clientRunId);
}
return { aborted: true };
}