Error on Ubuntu using Firefox/Chromium snaps
Opened this issue · 0 comments
If you are using Ubuntu 24.04 (or likely other Debian/Linux systems) with the following browser config:
"browser": {
"name": "firefox"
}
…then Tachometer v0.7.1 will error with the following message:
InvalidArgumentError: binary is not a Firefox executable
at Object.throwDecodedError (.../node_modules/selenium-webdriver/lib/error.js:521:15)
at parseHttpResponse (.../node_modules/selenium-webdriver/lib/http.js:514:13)
at Executor.execute (.../node_modules/selenium-webdriver/lib/http.js:446:28)
at processTicksAndRejections (node:internal/process/task_queues:105:5)
The solution is to use a config like the following:
"browser": {
"name": "firefox",
"binary": "/snap/firefox/current/usr/lib/firefox/firefox"
}
Similarly, if you have a snap-based Chromium installed, then you must use the following config to run Chromium:
"browser": {
"name": "chrome",
"binary": "/snap/chromium/current/usr/lib/chromium-browser/chrome"
}
I'm not sure if this is something that Tachometer should try to fix by default. On Ubuntu, it is possible to install non-snap-based Firefox, although you have to use workarounds since apt install firefox
will actually give you the snap. As for Chromium – if you install Chrome using the standard instructions from Google's website, then you'll get a non-snap-based version of Chrome, and Tachometer will work out of the box. However, I'm opening this issue since at least it might help someone who is stuck with the same error.