bitwarden / clients

Bitwarden client apps (web, browser extension, desktop, and cli).
https://bitwarden.com
Other
9.01k stars 1.18k forks source link

Multiple errors reported by Firefox devtools when Bitwarden installed #1801

Closed setyb closed 2 years ago

setyb commented 3 years ago

Describe the Bug

Multiple errors reported by Firefox devtools when Bitwarden installed

Steps To Reproduce

  1. Create a brand new Firefox profile and open Firefox using it
  2. Install Bitwarden extension from AMO
  3. Open Firefox's devtools
  4. Go to about:debugging
  5. Click on 'This Firefox'
  6. Click on the 'Inspect' button next to 'Bitwarden - Free Password Manager'
  7. Click on the Console tab
  8. Notice all the errors in the devtools console
  9. Click on 'analytics.ts' near upper right of console
  10. Notice more errors in the devtools console
  11. Repeat steps 2-10 in a well-used Firefox profile with many other extensions (such as uBO - uBlock Origin, Tab Reloader, Dark Reader, Custom Scrollbars, Sidebery, SingleFile, HTTPZ, et. al.)
  12. Notice even more errors in the devtools console that only exist when Bitwarden is installed

Expected Result

No errors in the console, even when Bitwarden is installed.

Actual Result

Here is a copy of the console errors, and you should also be able to generate them when you follow the STR:

unreachable code after return statement
2 analytics.ts:58:8
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 8 background.js:2176
    send browserMessaging.service.ts:6
unreachable code after return statement
analytics.ts:58:8
Content Security Policy: The page’s settings blocked the loading of a resource at eval (“script-src”). 10 vendor-angular.js:5707:20
Source map error: Error: NetworkError when attempting to fetch resource.
Resource URL: moz-extension://[UUID]/popup/vendor-angular.js
Source Map URL: scrolling.js.map

Source map error: Error: NetworkError when attempting to fetch resource.
Resource URL: moz-extension://[UUID]/popup/vendor.js
Source Map URL: auditTime.js.map

Source map error: Error: NetworkError when attempting to fetch resource.
Resource URL: moz-extension://[UUID]/vendor.js
Source Map URL: HttpClient.js.map

Source map error: Error: NetworkError when attempting to fetch resource.
Resource URL: moz-extension://[UUID]/popup/vendor-angular.js
Source Map URL: scrolling.js.map

unreachable code after return statement
2 analytics.ts:58:8
unreachable code after return statement
2 analytics.ts:58:8

Environment

Tested with Bitwarden v1.49.1 on Firefox 88.0 64-bit

martinmunk commented 3 years ago

I'm also getting hundreds of the first error message (background.js). I recently started having every other tab I open just be unresponsive, not sure if it's related but seems likely.

OS: PopOS 20.10 Browser: Firefox 88.0 BW plugin: 1.49.1

eliykat commented 3 years ago

unreachable code after return statement should be solved in the upcoming release - we had sinkholed our analytics with an early return statement rather than removing the code, but some cleanup work has now been done on that.

Unchecked lastError value is a duplicate of #1791.

Not sure about the Source Map errors. I'd be surprised if these errors are causing slowdown but I guess I can't rule it out without looking into it further.

bitwarden-bot commented 2 years ago

Hi @setyb, We're cleaning up our repositories in preparation for a major reorganization. Issues from last year will be marked as stale and closed after two weeks. If you still need help, comment to let us know and we'll look into it. Thanks!