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

Install correct Chromedriver version #68

Conversation

Mr0grog
Copy link
Owner

@Mr0grog Mr0grog commented Jun 21, 2023

Tests recently started failing in GitHub actions, and it's because the pre-installed version of Chrome and the version of Chromedriver specified in package.json fell out of sync. This installs the latest Chromedriver, but also adds some NPM configuration options to make this future-proof by installing the correct, matching versions of Chromedriver and Chromium itself, rather than the specific on in package.json.

As a side note, it seems like we should only need to specify include_chromium=true (so we have a version of Chromium that matches Chromedriver), but that setting is ignored unless detect_chromedriver_version=true is also set, which seems counterintuitive to me (if you are installing a compatible chromium, you shouldn’t need to detect the version, since you are installing a known-compatible version, but maybe I’ve got the mental model wrong here).

Mr0grog added 3 commits June 20, 2023 17:41
Tests recently started failing in GitHub actions, and it's because the pre-installed version of Chrome and the version of Chromedriver specified in `package.json` fell out of sync. This installs the latest Chromedriver, but also adds some NPM configuration options to make this future-proof by installing the correct, matching versions of Chromedriver and Chromium itself, rather than the specific on in `package.json`.
@Mr0grog
Copy link
Owner Author

Mr0grog commented Jun 21, 2023

As a side note, it seems like we should only need to specify include_chromium=true (so we have a version of Chromium that matches Chromedriver), but that setting is ignored unless detect_chromedriver_version=true is also set

Ah, I misread the docs; include_chromium is not downloading Chromium (which I thought it was); it’s just saying that it’s OK to to fall back to Chromium if Chrome isn’t detected.

I’ve removed that line, since it’s not what I want here, and tested that detect_chromedriver_version works correctly with a current Chrome installed but different versions of chromedriver in package.json. Should be all good now.

@Mr0grog Mr0grog merged commit 1cb7e71 into main Jun 21, 2023
@Mr0grog Mr0grog deleted the chrome-and-chromedriver-and-chromedriver-wrapper-are-talking-past-each-other branch June 21, 2023 01:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant