Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Firefox: Event pages and unexpected property warnings on extension reload #384

Open
Neved4 opened this issue Jun 11, 2020 · 1 comment
Open

Comments

@Neved4
Copy link

Neved4 commented Jun 11, 2020

Affects Firefox 77.0.1, Asciidoctor.js Live Preview 2.6.0.1 and previous 2.5.0.

Description

Reloading the extension causes some warnings. It does not prevent proper display of the document.

Steps to reproduce

  1. Reload the extension with or without an AsciiDoc(tor) file.

Warning Details

Reading manifest: Warning processing background.
persistent: Event pages are not currently supported.
This will run as a persistent background page.
Reading manifest: Warning processing options_page:
An unexpected property was found in the WebExtension
manifest.
Extension ID
asciidoctor-firefox-addon@asciidoctor
Internal UUID
c2388f31-ea60-d048-ab0d-ecb9ab5190df
Manifest URL
moz-extension://c2388f31-ea60-d048-ab0d-ecb9ab5190df/manifest.json

Possibly Related

#302 produces equivalent warnings, but by reloading they can be triggered without using the include directive.

Attachments

Screenshot


@ggrossetie
Copy link
Member

Unfortunately, this option is not supported by Firefox hence the warning message.
Currently, we are using the same manifest for Firefox and Chromium-based browsers but we could decide to use specific manifest for Firefox.
The warning message is annoying and confusing but I'm not sure it's worth it maintenance wise to build two packages (instead of one) with a specific manifest to accommodate Firefox.

Another idea would be to use background.persistent: true but I think it's better to use a non persistent page (when possible):

true indicates the background page is to be kept in memory from when the extension is loaded or the browser starts until the extension is unloaded or disabled, or the browser is closed (i.e. the background page is persistent).

https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/manifest.json/background

Regarding the warning message about the deprecated options_page property, I've removed/replaced it in #387

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants