Firefox reporting errors, can't find profile on new FreeBSD install

FreeBSD 13.1-RELEASE-p6 FreeBSD 13.1-RELEASE-p6 GENERIC amd64
Firefox 111.0.1_2,2 installed via pkg from the Quarterly Repo.

Brand new install. Tried removing ~/.mozilla and reinstalling firefox with no luck.
To be honest, I had this problem half a year ago when I tried FreeBSD - had the same problem with firefox back then as well.

1. Starting firefox from the command line with 'firefox &', I see this leftover JavaScript error in the terminal:
console.error: ({})
JavaScript error: resource://gre/modules/XULStore.jsm, line 58: Error: Can't find profile directory.

2. When firefox is closed, this huge chunk of error messages are displayed in the terminal:
WARNING: A blocker encountered an error while we were waiting.
Blocker: Waiting for ping task
Phase: TelemetryController: Waiting for pending ping activity
State: (none)
WARNING: Error: Phase "profile-before-change" is finished, it is too late to register completion condition "OS.File: flush I/O queued before profileBeforeChange"
WARNING: addBlocker@resource://gre/modules/AsyncShutdown.sys.mjs:727:15
addBlocker@resource://gre/modules/AsyncShutdown.sys.mjs:523:26
addBlocker@resource://gre/modules/AsyncShutdown.sys.mjs:458:15
setupShutdown@resource://gre/modules/osfile/osfile_async_front.jsm:1548:28
@resource://gre/modules/osfile/osfile_async_front.jsm:1568:16
@resource://gre/modules/osfile.jsm:12:30
@resource://gre/modules/TelemetryStorage.sys.mjs:10:28
_checkPendingPings@resource://gre/modules/TelemetrySend.sys.mjs:863:17
setup@resource://gre/modules/TelemetrySend.sys.mjs:803:18
setup@resource://gre/modules/TelemetrySend.sys.mjs:241:30
setupTelemetry/this._delayedInitTask<@resource://gre/modules/TelemetryControllerParent.sys.mjs:828:36
observe@resource://gre/modules/AsyncShutdown.sys.mjs:576:16

console.error: "TelemetryScheduler.shutdown - Already shut down"
WARNING: A blocker encountered an error while we were waiting.
Blocker: TelemetryController: shutting down
Phase: profile-before-change-telemetry
State: Error getting state: Error: Phase "profile-before-change" is finished, it is too late to register completion condition "OS.File: flush I/O queued before profileBeforeChange" at addBlocker@resource://gre/modules/AsyncShutdown.sys.mjs:727:15
addBlocker@resource://gre/modules/AsyncShutdown.sys.mjs:523:26
addBlocker@resource://gre/modules/AsyncShutdown.sys.mjs:458:15
setupShutdown@resource://gre/modules/osfile/osfile_async_front.jsm:1548:28
@resource://gre/modules/osfile/osfile_async_front.jsm:1568:16
@resource://gre/modules/osfile.jsm:12:30
@resource://gre/modules/TelemetryStorage.sys.mjs:10:28
_checkPendingPings@resource://gre/modules/TelemetrySend.sys.mjs:863:17
setup@resource://gre/modules/TelemetrySend.sys.mjs:803:18
setup@resource://gre/modules/TelemetrySend.sys.mjs:241:30
setupTelemetry/this._delayedInitTask<@resource://gre/modules/TelemetryControllerParent.sys.mjs:828:36
observe@resource://gre/modules/AsyncShutdown.sys.mjs:576:16

WARNING: [Exception... "Component returned failure code: 0x80040111 (NS_ERROR_NOT_AVAILABLE) [nsITelemetry.msSinceProcessStartExcludingSuspend]" nsresult: "0x80040111 (NS_ERROR_NOT_AVAILABLE)" location: "JS frame :: resource://gre/modules/TelemetrySession.sys.mjs :: getSessionPayload :: line 747" data: no]
WARNING: getSessionPayload@resource://gre/modules/TelemetrySession.sys.mjs:747:28
saveShutdownPings@resource://gre/modules/TelemetrySession.sys.mjs:953:34
shutdownChromeProcess/cleanup/<@resource://gre/modules/TelemetrySession.sys.mjs:1224:20
cleanup@resource://gre/modules/TelemetrySession.sys.mjs:1231:9
shutdownChromeProcess@resource://gre/modules/TelemetrySession.sys.mjs:1248:14
shutdown@resource://gre/modules/TelemetrySession.sys.mjs:239:17
_cleanupOnShutdown@resource://gre/modules/TelemetryControllerParent.sys.mjs:938:35
observe@resource://gre/modules/AsyncShutdown.sys.mjs:576:16

JavaScript error: resource://gre/modules/AsyncShutdown.sys.mjs, line 727: Error: Phase "profile-before-change" is finished, it is too late to register completion condition "OS.File: flush I/O queued before profileBeforeChange"
JavaScript error: resource://gre/modules/AsyncShutdown.sys.mjs, line 727: Error: Phase "profile-before-change" is finished, it is too late to register completion condition "OS.File: flush I/O queued before profileBeforeChange"
JavaScript error: resource://gre/modules/AsyncShutdown.sys.mjs, line 727: Error: Phase "profile-before-change" is finished, it is too late to register completion condition "OS.File: flush I/O queued before profileBeforeChange"
JavaScript error: resource://gre/modules/TelemetrySession.sys.mjs, line 747: NS_ERROR_NOT_AVAILABLE: Component returned failure code: 0x80040111 (NS_ERROR_NOT_AVAILABLE) [nsITelemetry.msSinceProcessStartExcludingSuspend]

3. Normally I start firefox through rofi so I wasn't even aware of all these residual errors that were left over each time I start/close firefox. And even with all these errors, firefox ran okay...... Until I try clicking an URL link from weechat or elsewhere or trying to start another instance of firefox. When I do that I get this pop-up message telling me that firefox is already running but is not responding. and that to use firefox, i must first close the existing firefox process, restart my device or use a different profile.
So at the moment I'm unable to just click on a link and have it be opened in firefox nor can I try to start another firefox window instance.

fox2.png


4. So I looked into the ~/.mozilla folder and here are the files and their contents:
Here is a picture of my ~/.mozilla/firefox (brand new firefox package install):
mozilla1.png

two profiles/folders were created. the l3ut3ono.default-release being the one being utilized as my profile and here are the contents inside that folder:
mozilla2.png


Here is the content inside the file 'installs.ini':
mozilla3.png


Here is the content of the file 'profiles.ini':
mozilla4.png


So the profile i'm on is being "LOCKED"? and there's no 'PATH=' for it either. Is that why firefox is saying it can't find the profile directory? What about all those JavaScript errors? are they all related? I really haven't done any configurations or changes to my FreeBSD. It's a brand new FreeBSD and Firefox installation. ?

Any help will be greatly appreciated.
 
launching firefox with 'firefox -p' to choose another profile didn't work.
deleting both of those default profiles and manually creating a new one didn't work.
going into profiles.ini and deleting the 'Locked=1' parameter for the profile didn't work.
Adding Path parameter didn't work.
sigh. nothing seems to work :(

I searched around online and while this bug was brought up a few times, I don't really see anyone pointing to a real solution and the discussions mostly went unresolved. 1 or 2 people did mention the problem resolving itself after an upgrade. one person mentioned he solved it by chown -R $USER:$USER the ~/.cache folder. But, i noticed this problem previously in the past when i tried FreeBSD half a year or a year ago and had the same problem and this time around it's still there so a simple update/upgrade certainly isn't a solution. and i don't see how chown -R the .cache folder could've solved the problem either considering ~/.cache is already under my ownership already.

you guys don't have this problem when using firefox? ?‍?
 
SOLVED by adding dbus_enable="YES" to rc.conf
I'm using a Window Manager instead of a Desktop Environment so I didn't know dbus_enable was something i needed.
Only saw it in the handbook for DE installation for KDE, GNOME, etc. So didn't know it was something this ubiquitous.
 
Back
Top