From 7638e4e4568fc59577446d143a951a573d86ea81 Mon Sep 17 00:00:00 2001 From: Dan Shapiro Date: Sat, 9 May 2026 11:13:12 -0700 Subject: [PATCH 1/2] fix: skip persist on cross-tab recency prune to prevent ping-pong The prune dispatch in handleIncomingRaw lacked skipPersist, causing each tab to write its pane set back to localStorage after receiving remote recency data. Since non-overlapping tabs have different pane IDs, the raw values alternate and the dedupe mechanism (overwritten by onPersistBroadcast each iteration) never catches them, creating an infinite cross-tab localStorage write loop. --- src/store/crossTabSync.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/store/crossTabSync.ts b/src/store/crossTabSync.ts index f4c3c9fd7..9cfd7af8e 100644 --- a/src/store/crossTabSync.ts +++ b/src/store/crossTabSync.ts @@ -281,7 +281,7 @@ function handleIncomingRaw( ...prunePaneTabActivityToLiveTerminalPanes({ paneIds: collectLiveTerminalPaneIds(store.getState()), }), - meta: { source: 'cross-tab' }, + meta: { skipPersist: true, source: 'cross-tab' }, }) } } From a4c1b6e7b7efbc31294c4a4e56451bf9e28dc09d Mon Sep 17 00:00:00 2001 From: Dan Shapiro Date: Mon, 18 May 2026 04:17:54 -0700 Subject: [PATCH 2/2] fix: persist pruned tab recency sidecars --- src/store/crossTabSync.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/store/crossTabSync.ts b/src/store/crossTabSync.ts index 9cfd7af8e..f4c3c9fd7 100644 --- a/src/store/crossTabSync.ts +++ b/src/store/crossTabSync.ts @@ -281,7 +281,7 @@ function handleIncomingRaw( ...prunePaneTabActivityToLiveTerminalPanes({ paneIds: collectLiveTerminalPaneIds(store.getState()), }), - meta: { skipPersist: true, source: 'cross-tab' }, + meta: { source: 'cross-tab' }, }) } }