-
-
Notifications
You must be signed in to change notification settings - Fork 390
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
Privacy Badger failed to initialize #2966
Comments
Hello and thank you for opening an issue! When Privacy Badger says that it failed to initialize, could you take a screenshot of Privacy Badger's background page? To open Privacy Badger's background page in Firefox:
Let me know if you have any questions. |
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
The screenshot only shows output from running the debugging command, which we don't need to do now. What I am looking for is the error that breaks Privacy Badger when Privacy Badger first starts up. Could you visit And then could you take and post another screenshot of Privacy Badger's background page? No need to put in any debugging code. I just want to see the errors that come up by themselves. |
It looks like your Firefox extension storage is failing to return an expected object. I am not sure why we don't see the complete error information ("stack trace"), or why we don't see the storage error. But that's what I think it is. The good news, sort of, is that this kind of problem was happening before I added the logic to show the "failed to initialize" error message. It's just that before we didn't know that your Privacy Badger was broken, and now we do. So now that we know, we'll try to fix or work around this problem. |
This is related to #2954. |
Ping me if you need testing/triage on possible solutions. |
If you use any other extensions, have you noticed anything strange about them? For example, your extension settings get reset to defaults after restarting the browser. |
This comment was marked as outdated.
This comment was marked as outdated.
@ppseprus That looks like a screenshot of the dev tools console for Privacy Badger's popup. Could you try opening the dev tools console for Privacy Badger's background process, next time the red exclamation comes up? To reach the background process in Chrome, visit |
@ghostwords , it opens the same thing. I tried both ways (from extensions, clicking the service worker label AND the popup option in the dropdown. ![]()
Since I updated the browser about an hour ago, PB stopped working on every single tab. No matter which one I open up. I completely stopped working. |
What do you mean by "stopped working"? Is the popup blank? Does restarting Privacy Badger help? To restart, visit |
OK thank you! I'll upload a workaround update shortly. I'll let you know when it goes live so that we can look if things got better. Might happen by tomorrow, but maybe Monday. |
Huh, I wonder if restarting the browser can somehow lead to this error. Like, something about extension storage not being ready even though extensions are already running and expect |
I have not. |
My latest theory is that there are two separate issues that people run into:
As a workaround, users can restart Privacy Badger by visiting their browser's extensions management page, and toggling Privacy Badger off and then back on. I am not sure this workaround helps for (2) though, when PB fails to read from extension storage. We're about to release a partial fix for (2), when PB fails to read from extension storage. Rather than failing completely, Privacy Badger will initialize as if freshly installed, with all settings at defaults. We won't show the new user welcome page though. We are going to follow this up with a fix for (1) where we deactivate the "failed to initialize" error when PB does in fact finish initializing successfully. Also for (1), I am going to look into if we can do anything about Privacy Badger taking longer than ten seconds to initialize. Also for (2), I am going to look into retrying reading from extension storage, rather than giving up after the first attempt fails. |
I am getting this exact issue now on Chrome. |
Try restarting Privacy Badger by going to |
Same Problem with: |
Yes, I think so. Then the following earlier posts apply to your problem:
We are waiting on approval from Mozilla, and that unfortunately always seems to take a few days these days. |
For reference, this has also been happening in Edge since last week. |
This worked for me |
It worked, but sometimes not the first restart |
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as resolved.
This comment was marked as resolved.
These fixes are live as of Privacy Badger version 2024.6.3. Thanks everybody for your help and patience! |
I'm still looking into followup improvements.
The initialization delays seem to come from trying to read from "managed" extension storage. The We may be able to work around this browser bug by not waiting to read from managed storage. Unfortunately, this means that users' policy-set preferences will not get applied until some time after websites and Privacy Badger both got going. But if it's between Privacy Badger not being ready to do its job for 10+ seconds on browser startup for all users, and Privacy Badger failing to apply admin policy-set preferences until 10+ seconds on browser setup for admin policy users, I think the latter is the less-bad option.
Apparently, regular extension storage can silently fail and return |
Things seem to be working for Edge also (at least no error message shown). |
I am getting the same issue no matter how many times I restart privacy badger or my browser. Chrome: Version 125.0.6422.142 (Official Build) (arm64) |
Hi @Aenimus, could you open a new issue please? We are going to want to debug what's going on, but I don't want to reuse this thread, as the "failed to initialize" problem seems to be fixed for most users. |
Understood and my apologies @ghostwords. |
The followup improvements described in #2966 (comment) are live as of Privacy Badger version 2024.6.14. |
What is your browser and browser version?
Firefox_v126.0
What is broken and where?
All sites I visit e.g. 'eff.org', 'fsf.org' etc.
The text was updated successfully, but these errors were encountered: