From c2c3058ecad2661d4ae7d362154ee0610d25ad96 Mon Sep 17 00:00:00 2001 From: Al Zilla Date: Mon, 17 Aug 2026 13:32:39 -0600 Subject: [PATCH] fix(desktop): never spawn SSH dashboards just to list Bot Mode agents A leftover sshConnections key made roster polling call ensureRegistryBackend for every SSH source every ~5s. That spawned remote dashboards, the mux died, and the renderer hit hermes:api ECONNRESET / liveness-probe drops. SSH inventory stays on the cached ls path only. Clicking a bot still dials that one source. --- apps/desktop/electron/main.ts | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/apps/desktop/electron/main.ts b/apps/desktop/electron/main.ts index ec15ce3920..771a370891 100644 --- a/apps/desktop/electron/main.ts +++ b/apps/desktop/electron/main.ts @@ -12552,10 +12552,11 @@ async function enumerateRegistryAgentSources(registry = readDesktopConnectionsRe let raw: { connection: typeof connection; error?: string; profiles: null | string[] } try { - if ( - connection.kind === 'ssh' && - ![...sshConnections.keys()].some(scope => String(scope).startsWith(backendScopePrefix(connection.id))) - ) { + // SSH roster listing must never spawn a dashboard. A stale + // sshConnections key used to fall into ensureRegistryBackend and + // respawn Spark/Mini every Bot Mode poll (~5s), then the mux died + // (ECONNRESET / liveness probe drop). + if (connection.kind === 'ssh') { await probeSshProfileInventory(connection) raw = { connection, profiles: null, error: 'connect-on-demand' } } else {