Skip to content
This repository has been archived by the owner on Jan 30, 2024. It is now read-only.

Try to fix chromedriver hanging on chrome #9348

Merged
merged 1 commit into from
Jul 8, 2019
Merged

Conversation

benthorner
Copy link
Contributor

@benthorner benthorner commented Jul 8, 2019

https://trello.com/c/ReXsdUoO/630-icinga-unknown-alert-tmp-smokeyjson-is-older-than-30m

Recently we saw the smokey tests were hanging on production (AWS). On
investigating the issue, we found that chrome was failing to respond to
Chromedriver commands. The interaction between chromedriver and Chrome
is done in the context of a session [1]; we were able to get the active
session ID by doing an 'strace' of the chrome/driver processes.

curl -d '{"url":"https://www.google.com"}' http://localhost:9515/session/27f4262ab044392b05138540055a8fd6/url

This provided some clarity on the reason for the smokey tests hanging,
and lead to the following issue, which suggests the issue is related to
'dbus': SeleniumHQ/docker-selenium#87. While
this seems to be part of the main Chromium distribution [3], it's not
clear if this has made it into Chrome itself.

This trials implementing the suggested fix for the smokey process.

References

[1] https://www.pawangaria.com/post/automation/browser-automation-from-command-line/
[2] https://chromium.googlesource.com/chromium/src/+/2fc330d0b93d4bfd7bd04b9fdd3102e529901f91%5E%21/
[3] https://chromium.googlesource.com/chromium/src/+/refs/heads/master/services/service_manager/embedder/main.cc#274

Recently we saw the smokey tests were hanging on production (AWS). On
investigating the issue, we found that chrome was failing to respond to
Chromedriver commands. The interaction between chromedriver and Chrome
is done in the context of a session [1]; we were able to get the active
session ID by doing an 'strace' of the chrome/driver processes.

curl -d '{"url":"https://www.google.com"}' http://localhost:9515/session/27f4262ab044392b05138540055a8fd6/url

This provided some clarity on the reason for the smokey tests hanging,
and lead to the following issue, which suggests the issue is related to
'dbus': SeleniumHQ/docker-selenium#87. While
this seems to be part of the main Chromium distribution [3], it's not
clear if this has made it into Chrome itself.

This trials implementing the suggested fix for the smokey process.

References
==========

[1] https://www.pawangaria.com/post/automation/browser-automation-from-command-line/
[2] https://chromium.googlesource.com/chromium/src/+/2fc330d0b93d4bfd7bd04b9fdd3102e529901f91%5E%21/
[3] https://chromium.googlesource.com/chromium/src/+/refs/heads/master/services/service_manager/embedder/main.cc#274
Copy link
Contributor

@cbaines cbaines left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good to me 👍

@benthorner benthorner merged commit e220121 into master Jul 8, 2019
@benthorner benthorner deleted the try-fix-smokey-hang branch July 8, 2019 14:44
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants