UserAgent-Switcher
UserAgent-Switcher copied to clipboard
Changing UA somehow makes request from Service Workers fail with NS_ERROR_INTERCEPTION_FAILED
I have no idea why this could happen. I noticed the problem on web.whatsapp.com where it won't load stickers with the extension enabled. I also had some font loading issues on other websites (for example the Italian news website corriere.it) which fail with the same error.
On the network tab I get this error:
I'm not even sure on how to reproduce this issue, the behavior I get is the following:
- I load a page using a different UA
- Resource
X
fails to load - I reset my UA and reload the page
-
X
loads just fine - I change my UA again
- I reload the page using the
Disable cache
option in the devtools -
X
still loads fine (somehow?) - If I try to load another resource
Y
that wasn't being loaded before it still fails with the same error
I think that this behavior is due to some kind of cache still being present that my browser is still accessing and it shouldn't be related to the extension itself but this behavior keeps me from submitting a fully reproducible example, so sorry about that.
I'll do some further investigation in the next days but I'm opening this issue anyways because maybe it's a known issue or it has a easy workaround available that I'm not aware of.
Setup information
- Browser: Librewolf 107.0.1 (basically Firefox)
- Extension version: 0.4.8 from the Firefox Store
As always, thank you for your time and for this extension :)
So that's why I couldn't get some websites to work. Thank you for bringing this up because I was pulling my hair out figuring out why so many essential CORS requests had been blocked on LibreWolf when i tried to explicitly allow it.
I did some research and some googling: turns out that the error I'm getting, NS_ERROR_INTERCEPTION_FAILED
, according to this reddit post, means
Generic error for non-specific failures during service worker interception
So the problems seems to be with the service worker, not every request, which could explain the behavior I was getting in the websites mentioned in the first commend.
This also means that my initial hypothesis on CORS was at least partially wrong, I'll update the title to make it more accurate.
NS_ERROR_INTERCEPTION_FAILED
is a very generic error, it's not very easy to find out what's going on..