From 3d7be8a55a31ff32de19452572d512e96b3a901e Mon Sep 17 00:00:00 2001 From: uinstinct <61635505+uinstinct@users.noreply.github.com> Date: Fri, 5 Dec 2025 09:40:06 +0530 Subject: [PATCH] fix: show the correct number of pending tools --- gui/src/pages/gui/ToolCallDiv/index.tsx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gui/src/pages/gui/ToolCallDiv/index.tsx b/gui/src/pages/gui/ToolCallDiv/index.tsx index 4374a264a..918c16d3f 100644 --- a/gui/src/pages/gui/ToolCallDiv/index.tsx +++ b/gui/src/pages/gui/ToolCallDiv/index.tsx @@ -29,8 +29,9 @@ export function ToolCallDiv({ const shouldShowGroupedUI = toolCallStates.length > 1 && isStreamingComplete; const activeCalls = toolCallStates.filter( - (call) => call.status !== "canceled" && call.status !== "done", + (call) => call.status !== "canceled", ); + const pendingCalls = toolCallStates.filter((call) => call.status !== "done"); const renderToolCall = (toolCallState: ToolCallState) => { const tool = availableTools.find( @@ -92,7 +93,7 @@ export function ToolCallDiv({
0 ? pendingCalls : activeCalls} open={open} onToggle={() => setOpen(!open)} />