gracefully handling corrupted / lost startupCache scenario
Categories
(WebExtensions :: General, enhancement, P3)
Tracking
(Not tracked)
People
(Reporter: mixedpuppy, Unassigned)
References
(Blocks 1 open bug)
Details
(Whiteboard: [addons-jira])
Instead of always starting up the background page once the browser startup is completed, start it:
- if no startupCache was available (or no persisted listeners/objects were available), automatically start the background string on addon startup
- If startupCache / persisted listeners / persisted extension objects are available, don’t start the background script until an event does trigger it
- Are there any APIs that would cause the background page to be loaded?
Updated•3 years ago
|
Comment 1•3 years ago
|
||
As the runtime.onInstalled
method is the documented way to register (persistent) rules/events, we should make sure that we dispatch this event if the rules/events are gone. Dispatched from https://searchfox.org/mozilla-central/rev/69a482382823f42f482e840f65725218d7654cc4/toolkit/components/extensions/parent/ext-runtime.js#56-70
Reporter | ||
Comment 2•3 years ago
|
||
runtime.onInstalled method is the documented way to register (persistent) rules/events
To be clear, events are documented to be persisted when the background page is loaded, not during onInstalled.
Comment 3•2 years ago
|
||
What is described in comment 0 has been included in the changes landed as part of Bug 1748524 (in particular nearby here) and so I'm marking this as a duplicate of that one.
If we determine something more to be done besides what comment 0 was describing, then we will file new bugs with details about the new specific cases that we want to consider some special handling for.
Description
•