You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A frozen tab is still fully loaded in memory, but Chrome pauses its JavaScript execution (timers, events, content scripts) to save resources.
Behavior when sending a message:
Chrome does attempt to deliver the message to the tab.
However, because the tab’s JavaScript is paused, the content script cannot run immediately.
When the tab is later unfrozen (e.g., becomes active), the content script will resume and then process the message.
Callback behavior:
The callback or promise resolution may be significantly delayed, depending on when the tab is unfrozen.
No error is thrown simply because the tab is frozen.
The message does not immediately fail.
It simply waits on the tab to resume execution.
Unfreezing:
Happens when:
The tab becomes the active tab, or
Chrome decides to resume it automatically.
In very recent Chrome versions (M124+), if the tab stays frozen for an extremely long time and the message queue grows too large, Chrome may eventually drop messages silently, but this is rare and still no error is thrown.
🗑️ Discarded Tab
A discarded tab is completely unloaded from memory. Its renderer process is gone, though the tab still appears in the tab strip with title + favicon.
Behavior when sending a message:
*When you send a message to a discarded tab:
Chrome detects immediately that there is no renderer → fails instantly.
The callback is invoked immediately with an error.
Reloading:
The tab reloads its page (and content scripts) when the user activates it.
Activity
chrome.tabs.sendMessage会出现Could not establish connection. Receiving end does not exist.#1022[-]ScriptCat 未处理 Discarded Tab, Frozen Tab[/-][+]ScriptCat 应处理 Frozen Tab 问题 (保留中)[/+]