From ed81f0b633c7c2ee9526b63be34fe0e5b13ab701 Mon Sep 17 00:00:00 2001 From: kshitijk4poor <82637225+kshitijk4poor@users.noreply.github.com> Date: Sun, 21 Jun 2026 20:41:31 +0530 Subject: [PATCH] fix(desktop): log session.title RPC failure before REST fallback The RPC-rename fallback swallowed all errors silently. Narrow it to log the swallowed error via console.warn so a genuine session.title RPC failure (which then surfaces a REST 404 for the runtime id) is diagnosable instead of invisible. Behavior is unchanged: REST fallback still runs for any session with a persisted row. --- apps/desktop/src/app/chat/sidebar/session-actions-menu.tsx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/apps/desktop/src/app/chat/sidebar/session-actions-menu.tsx b/apps/desktop/src/app/chat/sidebar/session-actions-menu.tsx index 4c973990499..4453097c044 100644 --- a/apps/desktop/src/app/chat/sidebar/session-actions-menu.tsx +++ b/apps/desktop/src/app/chat/sidebar/session-actions-menu.tsx @@ -59,9 +59,12 @@ export async function renameSessionPreferringRpc( }) return { title: result?.title ?? title } - } catch { + } catch (err) { // Fall through to REST — e.g. the socket is mid-reconnect. REST still - // works for any session that already has a persisted row. + // works for any session that already has a persisted row. Log so a + // genuine RPC-side failure (which then surfaces a REST 404 for the + // runtime id) is at least diagnosable instead of silently swallowed. + console.warn('session.title RPC rename failed; falling back to REST', err) } }