Problem
When new browser tabs are opened while GroupThink is active, they don't appear in the treemap view. The app loads from chrome.storage.local cache on mount and the background regroup mechanism doesn't reliably propagate updates to the UI.
Current behavior
- App loads → reads cached grouping from storage → displays it
- Background
scheduleRegroup() fires 10s after tab create/remove/URL change
- Background saves updated grouping to storage
- App has a
chrome.storage.onChanged listener + silent doGrouping() on initial load
- But new tabs still don't appear — the update path isn't working end-to-end
Expected behavior
New tabs should appear in the grouping within ~10-15 seconds of being opened, without requiring a manual Refresh click.
Investigation areas
- Is the background
scheduleRegroup actually firing? (check service worker console logs)
- Is
chrome.storage.onChanged listener receiving events in the app page context?
- Does the silent
doGrouping complete but the result get ignored due to state guards (loadingPhase !== "idle" check)?
- Race condition: silent regroup kicks off on mount, completes, but
loadingPhase is still not "idle" at that point?
- The
chrome.storage.onChanged listener checks loadingPhase !== "idle" || chatLoading — during silent regroup loadingPhase stays at "idle", so this guard should be fine. But verify.
Relevant code
src/app/index.tsx — initial load effect (line ~138), storage listener (line ~162), silent doGrouping
src/background/index.ts — scheduleRegroup() (line ~120), handleMessage("group-tabs")
src/lib/storage.ts — Storage.setGrouping()
Workaround
Click the "Refresh" button in the header to trigger a full regroup.
Problem
When new browser tabs are opened while GroupThink is active, they don't appear in the treemap view. The app loads from
chrome.storage.localcache on mount and the background regroup mechanism doesn't reliably propagate updates to the UI.Current behavior
scheduleRegroup()fires 10s after tab create/remove/URL changechrome.storage.onChangedlistener + silentdoGrouping()on initial loadExpected behavior
New tabs should appear in the grouping within ~10-15 seconds of being opened, without requiring a manual Refresh click.
Investigation areas
scheduleRegroupactually firing? (check service worker console logs)chrome.storage.onChangedlistener receiving events in the app page context?doGroupingcomplete but the result get ignored due to state guards (loadingPhase !== "idle"check)?loadingPhaseis still not"idle"at that point?chrome.storage.onChangedlistener checksloadingPhase !== "idle" || chatLoading— during silent regrouploadingPhasestays at"idle", so this guard should be fine. But verify.Relevant code
src/app/index.tsx— initial load effect (line ~138), storage listener (line ~162), silent doGroupingsrc/background/index.ts—scheduleRegroup()(line ~120),handleMessage("group-tabs")src/lib/storage.ts—Storage.setGrouping()Workaround
Click the "Refresh" button in the header to trigger a full regroup.