-
Notifications
You must be signed in to change notification settings - Fork 29.8k
start and stop chromedriver once per sub-shard; do not wait for it to quit #69443
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
It looks like this pull request may not have tests. Please make sure to add tests before merging. If you need an exemption to this rule, contact Hixie on the #hackers channel in Chat. Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing. |
| } | ||
| print('Stopping chromedriver'); | ||
| _chromeDriver.process.kill(); | ||
| while (await _isChromeDriverRunning()) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My assumption is that pinging the chromedriver while it's shutting down is what's triggering the issue in the client socket implementation, so removing the need to wait for chromedriver to shut down should also 🤞 fix the flakiness.
jonahwilliams
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
jonahwilliams
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Still LGTM
| ].map(_withChromeDriver).toList(); | ||
| ]; | ||
| await _ensureChromeDriverIsRunning(); | ||
| await _selectIndexedSubshard(tests, kWebLongRunningTestShardCount); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Suggestion:Shall we add a comment explaining why we shutdown?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure? All our tests try to shutdown processes they start. It's like tearDown. If you can think of something that would explain something special about chromedriver, I'd be happy to add it. LMK.
Description
Start one shared instance of chromedriver and quit it at the end. This removes the need to check for driver connection at the end of the test, which seems to be leaving sockets that are not fully closed.
Related Issues
Fixes #69421