diff --git a/src/renderer/src/lib/agent-hibernation-coordinator.ts b/src/renderer/src/lib/agent-hibernation-coordinator.ts index 15062527e8f..6497bd6fd77 100644 --- a/src/renderer/src/lib/agent-hibernation-coordinator.ts +++ b/src/renderer/src/lib/agent-hibernation-coordinator.ts @@ -133,6 +133,10 @@ async function collectRuntimePtyLiveness( const targets = getRuntimeLivenessTargetWorktrees(state, targetWorktreeId) const runtimeLivePtyIdsByWorktreeId: Record = {} const runtimeLivenessRequiredWorktreeIds = [...targets.keys()] + if (targets.size === 0) { + // Why: an all-local install has nothing to ask, so it must not pay the status scan below. + return { runtimeLivePtyIdsByWorktreeId, runtimeLivenessRequiredWorktreeIds } + } const completedTabIds = new Set() for (const entry of Object.values(state.agentStatusByPaneKey)) { const tabId = entry?.state === 'done' ? getEntryTabId(entry) : null