docker-selenium
docker-selenium copied to clipboard
[🐛 Bug]: Firefox driver fails when used in Selenium Grid
What happened?
When I run a very simple test locally against Chrome, Edge and Firefox, the test passes without any issue. However, if I run the same test against a Selenium Docker grid, the Firefox test seems to fail. I created a sample project here: https://github.com/ablok/selenium-firefox-issue
Command used to start Selenium Grid with Docker (or Kubernetes)
See sample project: https://github.com/ablok/selenium-firefox-issue
Relevant log output
This is the stacktrace I see:
WebDriverError: Failed to decode response from marionette
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 process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async Driver.execute (node_modules/selenium-webdriver/lib/webdriver.js:740:17)
at async Object.thenFinally [as finally] (node_modules/selenium-webdriver/lib/promise.js:100:5)
at async Context.<anonymous> (test.js:26:13)
Operating System
Mac M3
Docker Selenium version (image tag)
4.20.0-20240425
Selenium Grid chart version (chart version)
No response
@ablok, thank you for creating this issue. We will troubleshoot it as soon as we can.
Info for maintainers
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!
Can you share the Grid logs, please?
@diemol I did add the docker logs yesterday. Is this what you are looking for? Or do you need more?
Via logs, I saw a few messages that looks confused
firefox-1 | 2024-04-29T13:36:39.008880005Z 2024-04-29 13:36:39,008 INFO exited: browserleftoverscleanup (exit status 0; not expected)
firefox-1 | 2024-04-29T13:36:40.233644881Z 2024-04-29 13:36:40,233 INFO spawned: 'browserleftoverscleanup' with pid 104
firefox-1 | 2024-04-29T13:36:40.262890714Z 2024-04-29 13:36:40,262 INFO exited: browserleftoverscleanup (exit status 0; not expected)
firefox-1 | 2024-04-29T13:36:43.036568882Z 2024-04-29 13:36:43,036 INFO exited: browserleftoverscleanup (exit status 0; not expected)
firefox-1 | 2024-04-29T13:36:46.051412883Z 2024-04-29 13:36:46,051 INFO spawned: 'browserleftoverscleanup' with pid 196
firefox-1 | 2024-04-29T13:36:46.082746592Z 2024-04-29 13:36:46,082 INFO exited: browserleftoverscleanup (exit status 0; not expected)
firefox-1 | 2024-04-29T13:36:47.087824384Z 2024-04-29 13:36:47,087 INFO gave up: browserleftoverscleanup entered FATAL state, too many start retries too quickly
...
I haven't had time to check this, @ablok
browserleftoverscleanup
I think we need to change the configuration so it does not restart unless it is enabled.
@ablok try adjusting config on yaml for CPU and memory.. something like this...
containers:
resources:
limits:
cpu: 2300m
memory: 2600Mi
requests:
cpu: 1410m
memory: 1300Mi