Skip to content
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

fix: Retry when WebDriver updates are not available yet #24

Merged
merged 2 commits into from
Jul 19, 2023

Conversation

joeyparrish
Copy link
Member

Some WebDriver updates for Chrome and Edge lag behind the corresponding browser releases. This will automatically retry with the previous 2 releases when a 404 is encountered.

This fixes the failure on Chrome 115 today (ChromeDriver 115 is not out yet).

Some WebDriver updates for Chrome and Edge lag behind the
corresponding browser releases.  This will automatically retry with
the previous 2 releases when a 404 is encountered.

This fixes the failure on Chrome 115 today (ChromeDriver 115 is not
out yet).
@joeyparrish joeyparrish requested a review from theodab July 19, 2023 16:10
@joeyparrish joeyparrish changed the title fix: Retry when WebDriver updates are not available yet. fix: Retry when WebDriver updates are not available yet Jul 19, 2023

// Save the first error in case we run out this loop. We'll throw this
// one if none of the allowed versions can be found.
if (firstError == null) {
Copy link

Choose a reason for hiding this comment

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

nit; Can use a nullish coalescing assignment:

firstError ??= error;

Copy link
Member Author

Choose a reason for hiding this comment

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

This code doesn't get compiled, and nullish coalescing operators are only supported in node.js >= 14. That's not super new, but using that would also set a minimum requirement on this project and all dependent projects (like Shaka Player), so I would prefer not to use it.

Copy link
Member Author

Choose a reason for hiding this comment

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

In particular, node.js minimum requirements are a pain for people who use a package manager for node.js installation. Although node.js 14 came out in 2020, there is not yet an Ubuntu LTS release with node.js >= 14 in a native package. (Ubuntu LTS from 2020 has node.js v10 from 2018, Ubuntu LTS from 2022 has node.js v12 from 2019, etc. It sucks.)

@joeyparrish joeyparrish merged commit e0312c8 into shaka-project:main Jul 19, 2023
@joeyparrish joeyparrish deleted the retry branch July 19, 2023 17:55
joeyparrish pushed a commit that referenced this pull request Jul 19, 2023
🤖 I have created a release *beep* *boop*
---


##
[1.1.6](v1.1.5...v1.1.6)
(2023-07-19)


### Bug Fixes

* Ignore errors executing non-executable drivers
([#23](#23))
([07c8644](07c8644)),
closes
[#22](#22)
* Retry when WebDriver updates are not available yet
([#24](#24))
([e0312c8](e0312c8))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
joeyparrish added a commit to joeyparrish/karma-local-wd-launcher that referenced this pull request Jul 19, 2023
joeyparrish added a commit to shaka-project/karma-local-wd-launcher that referenced this pull request Jul 19, 2023
@github-actions github-actions bot added the status: archived Archived and locked; will not be updated label Sep 17, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 17, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
status: archived Archived and locked; will not be updated
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants