Closed jpilgrim closed 9 months ago
@jpilgrim, thank you for creating this issue. We will troubleshoot it as soon as we can.
Triage this issue by using labels.
If information is missing, add a helpful comment and then I-issue-template
label.
If the issue is a question, add the I-question
label.
If the issue is valid but there is no time to troubleshoot it, consider adding the help wanted
label.
If the issue requires changes or fixes from an external project (e.g., ChromeDriver, GeckoDriver, MSEdgeDriver, W3C),
add the applicable G-*
label, and it will provide the correct link and auto-close the
issue.
After troubleshooting the issue, please add the R-awaiting answer
label.
Thank you!
We should have removed the headless() method. You should set it as an argument; for firefox it is -headless
Oh, we deprecated it but didn't remove it. I'll go do that now.
You shouldn't need both: withCapabilities(webdriver.Capabilities.firefox())
& setFirefoxOptions(options)
, just use options; maybe that is creating invalid w3c capabilities?
@titusfortner Thanks for the quick answer. Alas it does not help. I removed the headless()
call (and replaced it with addArguments("--headless")
) and I also removed the .withCapabilities(webdriver.Capabilities.firefox())
call. No effect. Still, 4.8.1 is working, 4.8.2 and above are not.
I even removed the headless thing completely -- but without effect (except that I see the browser window now in 4.8.1, of course).
I updated my repo accordingly.
In the example "example/headless.js", the method headless is still used (selenium-webdriver 4.16.0) Note that in the firefox.d.ts file ("@types/selenium-webdriver": "^4.1.21"), headless is not marked as deprecated.
Also, activating logging as described on https://www.selenium.dev/documentation/webdriver/troubleshooting/logging/
has no effect: logging.getLogger('webdriver').setLevel(logging.Level.ALL)
I changed that to logging.getLogger(logging.Type.DRIVER + ".http").setLevel(logging.Level.ALL)
as it is done in selenium-webdriver/examples/logging.js.
Now, I can provide logs:
In 4.8.1, there are a lot of "slots" , including Firefox. In 4.8.2, only Safari is listed there.
Ah! I found the solution: I need to install geckodriver in version 4.8.2 (and higher), in 4.8.1 (and below) this is not required. This is a damned important change which is not reflected in a simple patch version bump!
So,
npm i geckodriver
solved the problem.
Anyway: I consider the current behaviour a bug. If the driver is not found (i.e. slot not available), an error must be thrown instead of not returning at all. This is why I leave this bug report open.
I'd be a lot more interested in seeing logs for 4.16 as we've made a bunch of changes to driver management since 4.8
Here is the 4.16.1 log (with uninstalled geckodriver)
I've sent a PR to your repository, which shows the changes you need to add to have this working.
The reason why it worked on that version and not on this one is Selenium Manager. We left it on by default in the Grid, and this was a mistake, because users should explicitly opt it to use it.
@diemol Thank you very much!
Actually it is already working, I only needed to install geckodriver. But I will try it with args: ['--selenium-manager', 'true']
as well. The timeouts are not that important (I mean, it worked with geckodriver).
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
What happened?
I'm using the standalone server jar and JavaScript for my tests on macos (14.1.1)
Long story short:
does not return since version 4.8.2.
Version up to 4.8.1 are working, but 4.8.2 (and above, including 4.16.1) are not working.
I assume this is a similar error as described in #13247
Longer story:
Starting the server with
works in all versions.
The firefox options are set as follows:
and then the (remote) browser or driver respectively is build (see short story above).
Has anything changed in the API since 4.8.2 related to this?
I have created a git repo with a demo: https://github.com/jpilgrim/selenium_remote_demo
Read the readme of that repo for details on how to run the tests in order to reproduce the bug.
How can we reproduce the issue?
Relevant log output
Operating System
macos 14.1.1
Selenium version
JavaScript
What are the browser(s) and version(s) where you see this issue?
Firefox 120.0.1 (64-bit) (using it remote)
What are the browser driver(s) and version(s) where you see this issue?
selenium-webdriver 4.16.0
Are you using Selenium Grid?
4.8.2