From f552820a75344e8563c7698d8793c9821ec946a4 Mon Sep 17 00:00:00 2001 From: Clawd Date: Thu, 22 Jan 2026 01:52:51 -0800 Subject: [PATCH] fix(bluebubbles): call stop typing on idle and NO_REPLY Previously, typing stop was intentionally skipped because the BlueBubbles Server DELETE endpoint was bugged (called startTyping instead of stopTyping). Now that the server bug is fixed, we can properly stop typing indicators. - onIdle: now calls sendBlueBubblesTyping(false) to stop typing - finally block: stops typing when no message sent (NO_REPLY case) --- extensions/bluebubbles/src/monitor.ts | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/extensions/bluebubbles/src/monitor.ts b/extensions/bluebubbles/src/monitor.ts index f55383068..ab503882d 100644 --- a/extensions/bluebubbles/src/monitor.ts +++ b/extensions/bluebubbles/src/monitor.ts @@ -1713,8 +1713,17 @@ async function processMessage( runtime.error?.(`[bluebubbles] typing start failed: ${String(err)}`); } }, - onIdle: () => { - // BlueBubbles typing stop (DELETE) does not clear bubbles reliably; wait for timeout. + onIdle: async () => { + if (!chatGuidForActions) return; + if (!baseUrl || !password) return; + try { + await sendBlueBubblesTyping(chatGuidForActions, false, { + cfg: config, + accountId: account.accountId, + }); + } catch (err) { + logVerbose(core, runtime, `typing stop failed: ${String(err)}`); + } }, onError: (err, info) => { runtime.error?.(`BlueBubbles ${info.kind} reply failed: ${String(err)}`); @@ -1754,7 +1763,13 @@ async function processMessage( }); } if (chatGuidForActions && baseUrl && password && !sentMessage) { - // BlueBubbles typing stop (DELETE) does not clear bubbles reliably; wait for timeout. + // Stop typing indicator when no message was sent (e.g., NO_REPLY) + sendBlueBubblesTyping(chatGuidForActions, false, { + cfg: config, + accountId: account.accountId, + }).catch((err) => { + logVerbose(core, runtime, `typing stop (no reply) failed: ${String(err)}`); + }); } } }