From c7dcba6b04191347a0cf5fa54356ebf3085f3df3 Mon Sep 17 00:00:00 2001 From: Classic298 <27028174+Classic298@users.noreply.github.com> Date: Tue, 17 Nov 2026 10:19:36 +0100 Subject: [PATCH] fix: a reply waiting for a tool approval is treated as finished (#34574) When a reply stopped to wait for a tool approval, the chat treated it as finished: Regenerate showed up on it while the approval was still open, and in a voice call the answer that followed the approval was never spoken. The chat now shows such a reply as still in progress until the approval is answered and the answer is complete, so Regenerate stays hidden and a voice call speaks the answer. Fixes #34572 --- src/lib/components/chat/Chat.svelte | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/lib/components/chat/Chat.svelte b/src/lib/components/chat/Chat.svelte index 50453a94ba..faa65b6e27 100644 --- a/src/lib/components/chat/Chat.svelte +++ b/src/lib/components/chat/Chat.svelte @@ -3391,7 +3391,10 @@ message?.role === 'assistant' && (message.user_id ?? chat?.user_id) === $user?.id && !message.done && - !messageHasPendingAskUser(message) + !messageHasPendingAskUser(message) && + !message.output?.some( + (item) => item?.type === 'function_call' && item?.status === 'pending' + ) ) { message.done = true; history = history;