-
-
Notifications
You must be signed in to change notification settings - Fork 368
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
[BUG] Regression in bgsw on Firefox: Could not resolve bundle with id X #628
Comments
It works on Chrome but not FF??? This is very weird because if you look at the diff between 0.74 -> 0.75, there's no change in the FF codepath. The last change to FF bundling happened in 0.74! xD... It is possible that Parcel upgrade might have introduced some weird stuff, however the fact that it works in Chrome but not FF shows it might not be the bundler but something else... |
@GarciaLnk would you mind creating a sample repro repo that I can clone and play around with |
Sure, here it is: https://github.com/GarciaLnk/sample-plasmo-bug |
@GarciaLnk should be fixed in latest patch |
Hm, I'm still getting the same "Could not resolve bundle" error after updating to v0.75.3. @louisgv do you not get any errors in the background script of the sample repo with the new patch? |
@GarciaLnk just re-tested again, you're right. The bundle stripped some module with es2022 minifier target. I updated it to es2022 in v0.76.0, should work now. |
It's kinda baffling that it works in dev mode but in prod mode even with minify turned off, it breaks???... I'm not entirely sure what the heck's going on lol bc dev mode and prod mode are not that diff with minify off... |
@GarciaLnk hmm.. it doesn't work on Chrome for me in 0.74.x either: BGSW cannot spawn worker in chrome, you will need to use #527 instead |
@GarciaLnk Found a fix to force single bundle to be produced. At least it works for me in Firefox, tho for chrome it's not possible to use web API in BGSW (since it's a SW runtime instead of page runtime like FF) xd |
That was not related to this issue, I just forgot to make the sample repo Chrome-compatible 😅 By default, the library spawns multiple workers to enable multithreading processing, but this can be worked around for Chrome's MV3 switching to single thread execution (with Anyways, v0.76.1 does seem to fix the issue on Firefox, however now I don't know how to access web-accessible resources on Chrome from the background service, since it now expects them to be at |
Can you ping me the exact issue you're seeing? If you use the Also a new issue would be great yeah - I just link issue to PR and they autoclose as a result of merging :p... |
@louisgv this bug is back with v0.76.2 |
Whoops my bad @GarciaLnk - can you try v0.76.3 |
Fixed, kudos |
I still have the issue with v0.77.5, and not just in Firefox, but in Chrome& Edge as well. |
@andrasbacsai can you open a new issue with a minimal reprod |
What happened?
I'm working with the following library in the background service worker of my extension: https://github.com/visheratin/web-ai
In Plasmo 0.74.2 everything worked fine on every browser (Firefox and Chromium-based), however after updating to Plasmo 0.75.2, I get an error on Firefox. It's worth noting that everything still works fine on Chromium-based browsers, and if I try to use the library in the popup, the error disappears.
This is the minimal reproducible example of the background.ts that triggers the error in 0.75.2:
I suspect this is yet another error related to Parcel.
Version
Latest
What OS are you seeing the problem on?
Linux
What browsers are you seeing the problem on?
Firefox
Relevant log output
(OPTIONAL) Contribution
Code of Conduct
The text was updated successfully, but these errors were encountered: