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

version 2.0.2+ doesn't work on Firefox: service_worker is not supported #147

Open
OnlyNandan opened this issue Oct 2, 2023 · 14 comments
Open

Comments

@OnlyNandan
Copy link

Installed v2.0.2. had to change manifest.txt as it gave me a /background/service_worker" is not supported error. so i changed it to

},
"background": {
"scripts": ["background.js"]
},

the add on was uploaded properly. but when i open whatsapp i get nothing in that extension
image

@tomer8007
Copy link
Owner

Hi,
I never designed this extension to work for Firefox, but first please try the 2.1.0 release I just published.
Also look for JS errors.

@OnlyNandan
Copy link
Author

Oh noted. I tried the 2.1.0 release and it have me the same "background.service_worker is currently disabled" error

@tomer8007
Copy link
Owner

This sounds like a manifest v2/v3 issue. Are you aware of #38?

@OnlyNandan
Copy link
Author

OnlyNandan commented Oct 3, 2023

yep i tried #38 and i was able to intstall vs 2.0.1 on firefox which worked flawlessly .

v 2.0.1
},
"background": {
"scripts": ["browser-polyfill.js", "background.js"]
},

and v 2.0.2

"background":
{
"service_worker": "background.js"
},
"host_permissions": ["https://web.whatsapp.com/*"],
"content_scripts":
[
{

there is a reference to service worker in v 2.0.2 and v 2.1.0

image

other errors can be resolved with the solutions present in #103

@tomer8007 tomer8007 changed the title "version 2.0.2 doesnt work on firefox" version 2.0.2+ doesn't work on Firefox: service_worker is not supported Oct 3, 2023
@tomer8007
Copy link
Owner

So what is your error currently?

@OnlyNandan
Copy link
Author

Main issue being that if i add v 2.0.1 to the ff then it get added and works without issue since it doesnt have background service worker. whereas the counterpart v 2.0.2 or 2.1.0 has background service worker which throws an error when added to ff. as ff doesnt support background service worker. and i was wondering if anyhow it would be possible to run the v2.0.2 upwards on ff.

@tomer8007
Copy link
Owner

The service worker is a manifest v3 thing I believe, so this makes sense. You could port it back to manifest v2 and convert the service worker to a background page just like you did. You could also figure out if Firefox supports manifest v3 (last time I checked it didn't).

@kamzone
Copy link

kamzone commented Oct 5, 2023

Hi.
You can try fixing it to work with firefox version of manifest v3 using this guide. Firefox made some changes to chrome implementation.
It worked for different extensions. I'll try doing it, and if it will work I'll post an update.

@OnlyNandan
Copy link
Author

Hey kamzone,
Thanks for the update ill try this out if i am able to get it to work ill update. i can get it to work please do the same.

@terrasaw
Copy link

Hi @OnlyNandan, did you manage to make it work?

@OnlyNandan
Copy link
Author

Hey,
Nope no luck as of now. only got the older versions running.

@bayazidbh
Copy link

bayazidbh commented Feb 17, 2024

For context - what does Firefox do differently or otherwise still not support that's making this remain a blocker for newer versions of the extension?

And what about version 2.0.1? Is that fine?

@OnlyNandan
Copy link
Author

For context - what does Firefox do differently or otherwise still not support that's making this remain a blocker for newer versions of the extension?

And what about version 2.0.1? Is that fine?

Its with regards to firefox not supporting manifest v3 yet

@bayazidbh
Copy link

@OnlyNandan is there something they haven't implemented yet, or something I'm missing, since according to this they already have it available?

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

No branches or pull requests

5 participants