Score:1

Firefox snap unable to open webpages via command line if Firefox is running

vn flag

I installed the Mozilla Firefox ESR snap using sudo snap install firefox --channel=esr/stable. When Firefox is not running, firefox 'https://askubuntu.com' successfully opens this website in Firefox. However, if there is an existing Firefox window, the same command would produce an error message: "Firefox is already running, but is not responding. To use Firefox, you must first close the existing Firefox process, restart your device, or use a different profile." How do I use the command line to open a webpage in an existing Firefox window?

Firefox version: 102.10esr. Ubuntu version: Ubuntu 20.04.6 LTS.

Terrance avatar
id flag
Might want to see https://askubuntu.com/questions/1376845/firefox-94-when-ran-from-a-crontab-claims-is-already-running-but-is-not-respon as it might be experiencing the same thing I was experiencing in Firefox 94. I ran `export DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/$(id -u)/bus` right before I would run Firefox from the command line.
guiverc avatar
cn flag
I'm not using your release (*and the default firefox snap version*), but when I copy & pasted your `firefox 'https://askubuntu.com'` onto my system, it just opened a new tab with the page on the command line on the firefox window I'm typing into now.
Flux avatar
vn flag
@Terrance `echo $DBUS_SESSION_BUS_ADDRESS` currently prints `unix:path=/run/user/1000/bus`, so I don't think that would help.
user535733 avatar
cn flag
Unable to reproduce the issue. On a stock 23.04 test system using the stock (non-ESR) Firefox snap, `firefox http://[url]` simply opens another tab in the currently-running application. See if you can reproduce the issue in the current (non-ESR) Firefox snap.
Terrance avatar
id flag
I can duplicate your issue in a 20.04.6 LTS VM running the esr/stable version of Firefox. Looks like you found a bug and I would suggest that you file one. Under `snap info firefox` there is a link on how to file a bug. This is not reproducible with the latest/stable Firefox snap in 20.04 LTS nor is it reproducible with the apt version 112 of Firefox.
markling avatar
cn flag
These "cannot duplicate" comments are unhelpful. I have the same problem with Firefox 113.0.02 snap install on Ubuntu 22.04.2 LTS. It is simply impossible to open a new window or tab programmatically to a profile that is already open. That means taskbar shortcuts or scripts. It renders Firefox useless on Ubuntu to all but the most basic usage. It seems the only solution is to use Chrome or ditch the Firefox snap.
markling avatar
cn flag
Although @tim-richardson says a non-snap from a Firefox download installer has the same problem.
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.