Skip to content

Support development ChromeDriver version overrides#606

Merged
dhh merged 1 commit intohotwired:mainfrom
seanpdoyle:intern-chromedriver-version
Jun 22, 2022
Merged

Support development ChromeDriver version overrides#606
dhh merged 1 commit intohotwired:mainfrom
seanpdoyle:intern-chromedriver-version

Conversation

@seanpdoyle
Copy link
Copy Markdown
Contributor

@seanpdoyle seanpdoyle commented Jun 20, 2022

Refines the changes introduced to the CI configuration made in
b1cbe12.

Recent Chrome upgrades are causing errors like the following while
executing the test suite locally:

SessionNotCreatedException: [POST http://localhost:4444/wd/hub/session / {"desiredCapabilities":{"name":"intern","idle-timeout":60,"browserName":"chrome","goog:chromeOptions":{"args":["headless","disable-gpu","no-sandbox"]},"browser":"chrome"}}] session not created: This version of ChromeDriver only supports Chrome version 99
Current browser version is 102.0.5005.115 with binary path

The only supports Chrome version 99 portion is due to digdug's
locked-support for Chrome version 99 declared in its webdrivers.json
file.

This commit checks for the presence of the CHROMEWEBDRIVER environment
variable, and overrides the intern.json configuration
to incorporate that into its tunnelOptions.drivers value.

- name: Set Chrome Version
run: |
CHROMEVER="$(chromedriver --version | cut -d' ' -f2)"
export CHROMEVER="$(chromedriver --version | cut -d' ' -f2)"
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@keithamus and @koddsson this incorporates the CI configuration you two introduced in b1cbe12 to support development-environment configurations.

It's still an incomplete developer experience and requires an awareness of your local chrome driver version.

On top of that, I'm not sure how to programmatically set a GitHub actions environment variable in this way, export doesn't seem to cut it.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

On top of that, I'm not sure how to programmatically set a GitHub actions environment variable in this way, export doesn't seem to cut it.

Evidently, piping an assignment into $GITHUB_ENV does the trick!

@seanpdoyle seanpdoyle force-pushed the intern-chromedriver-version branch 2 times, most recently from c9cef27 to b83c04d Compare June 20, 2022 15:49
Refines the changes introduced to the CI configuration made in
[b1cbe12][].

Recent Chrome upgrades are causing errors like the following while
executing the test suite locally:

```
SessionNotCreatedException: [POST http://localhost:4444/wd/hub/session / {"desiredCapabilities":{"name":"intern","idle-timeout":60,"browserName":"chrome","goog:chromeOptions":{"args":["headless","disable-gpu","no-sandbox"]},"browser":"chrome"}}] session not created: This version of ChromeDriver only supports Chrome version 99
Current browser version is 102.0.5005.115 with binary path
```

The **only supports Chrome version 99** portion is due to `digdug`'s
locked-support for Chrome version 99 declared in its [webdrivers.json][]
file.

This commit checks for the presence of the `CHROMEVER` environment
variable, and overrides the [intern.json](./intern.json) configuration
to incorporate that into its `tunnelOptions.drivers` value.

[webdrivers.json]: https://github.com/theintern/digdug/blob/806dcf29c2265d3cb1a26a09ef5b43e93fc2a739/src/webdrivers.json#L8-L11
[b1cbe12]: hotwired@b1cbe12
@seanpdoyle seanpdoyle force-pushed the intern-chromedriver-version branch from b83c04d to 14656db Compare June 20, 2022 15:57
@dhh
Copy link
Copy Markdown
Member

dhh commented Jun 22, 2022

Is this ready to go or it needs feedback from @keithamus and @koddsson?

Copy link
Copy Markdown
Contributor

@keithamus keithamus left a comment

Choose a reason for hiding this comment

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

LGTM

@dhh dhh merged commit 50d8bd7 into hotwired:main Jun 22, 2022
@seanpdoyle seanpdoyle deleted the intern-chromedriver-version branch June 22, 2022 15:41
dhh pushed a commit to seanpdoyle/turbo that referenced this pull request Jul 15, 2022
* main:
  Drive Browser tests with `playwright` (hotwired#609)
  Allow Turbo Streams w/ GET via `data-turbo-stream` (hotwired#612)
  Only update history when Turbo visit is renderable (hotwired#601)
  Support development ChromeDriver version overrides (hotwired#606)
  Turbo stream source (hotwired#415)
  Expose Frame load state via `[complete]` attribute (hotwired#487)
dhh pushed a commit to feliperaul/turbo that referenced this pull request Jul 16, 2022
* main:
  Allow frames to scroll smoothly into view (hotwired#607)
  Export Type declarations for `turbo:` events (hotwired#452)
  Add .php as a valid isHTML extension (hotwired#629)
  Add original click event to 'turbo:click' details (hotwired#611)
  Drive Browser tests with `playwright` (hotwired#609)
  Allow Turbo Streams w/ GET via `data-turbo-stream` (hotwired#612)
  Only update history when Turbo visit is renderable (hotwired#601)
  Support development ChromeDriver version overrides (hotwired#606)
  Turbo stream source (hotwired#415)
  Expose Frame load state via `[complete]` attribute (hotwired#487)
  fix(ie/edge): form.method='delete', raises Invalid argument. (hotwired#586)
  Do not declare global types/constants (hotwired#524)
  Defensively create custom turbo elements (hotwired#483)
  Use `replaceChildren` in StreamActions.update (hotwired#534)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants