Problem/Motivation
In parent issue #3258933-51: [meta] Update JavaScript dependencies for Drupal 10 we discovered updating Nighwatch to the latest version breaks all nightwatch tests.
That's why we handle the update in this separate child issue.
Relevant comments from the parent issue
This seems the likely culprit to me:
- selenium-webdriver "4.3.1" + selenium-webdriver "4.6.1"Maybe we should split off the Nightwatch update into a separate child issue and get the other ones in whilst we investigate?
Spokje in #3258933-53: [meta] Update JavaScript dependencies for Drupal 10
Possibly related, see https://github.com/SeleniumHQ/docker-selenium/issues/1723. This caused FunctionalJavascript tests to fail for me and at least a handful of others. Also affects Drupal Test Traits. Pinning to selenium/standalone-chrome:4.5.2 resolved the issue. I suspect it's the same issue here.
mstrelan in #3258933-54: [meta] Update JavaScript dependencies for Drupal 10
$ yarn-lock-diff -o old.yarn.lock -n yarn.lock
┌──────────────────────────────┬───────────────┬────────────────┐
│ package name │ old version(s)│ new version(s) │
├──────────────────────────────┼───────────────┼────────────────┤
│ axe-core │ 4.5.1 │ 4.5.2 │
├──────────────────────────────┼───────────────┼────────────────┤
│ nightwatch │ 2.4.2 │ 2.5.2 │
├──────────────────────────────┼───────────────┼────────────────┤
│ selenium-webdriver │ 4.3.1 │ 4.6.1 │
├──────────────────────────────┼───────────────┼────────────────┤
│ untildify │ - │ 4.0.0 │
└──────────────────────────────┴───────────────┴────────────────┘
Proposed resolution
- yarn upgrade nightwatch
- Fix problems
- Review
- Commit
Remaining tasks
User interface changes
API changes
Data model changes
Release notes snippet
| Comment | File | Size | Author |
|---|---|---|---|
| #15 | 3323988-15.patch | 22.49 KB | longwave |
| #3 | 3323988-3.patch | 3.76 KB | spokje |
Comments
Comment #2
spokjeComment #3
spokjeComment #4
spokjeComment #5
effulgentsia commentedAlthough the parent issue is already tagged as a stable release blocker, I think we're now getting close enough to 10.0.0's scheduled release date, that it's time for the individual issues to also be tagged with that.
Comment #6
spokjeSo we know stuff breaks when we jump to 2.5.3.
Let's give the smallest upgrade a test-run, going to 2.5.0, which contains:
Comment #7
spokje...and let's test that only with Nightwatch tests for now.
Comment #8
spokjeRight, that didn't really help.
Looks like as soon as we update
selenium-webdriver, which happens in the first update, to nightwatch 2.5.0, we loose all contact with the selenium server in out tests.Comment #9
spokjeFWIW: If I run 10.x branches in DDEV with the applied patch and with the addition of https://github.com/drud/ddev-selenium-standalone-chrome, nightwatch tests are fine.
Even if I update the chromedriver to 107. it still works.
That makes me believe the "problem" might be in the
drupalci/chromedriver:productionDocker container.Comment #10
effulgentsia commentedIs there something that can be changed in https://git.drupalcode.org/project/drupalci_environments/-/blob/producti... to fix it? If so, let's open an issue in https://www.drupal.org/project/issues/drupalci_environments for that.
Comment #11
effulgentsia commentedhttps://github.com/SeleniumHQ/docker-selenium/issues/1723#issuecomment-1... has some info that might be relevant to #10, but I don't think I totally understand the implications of that comment.
Comment #12
effulgentsia commentedI discussed this with @xjm and @catch, and they agreed that this does not need to block a 10.0.0 release. We can do this in 10.1 if we're unable to do it before 10.0.
Comment #13
effulgentsia commentedNightwatch 2.5.4 has been released. https://github.com/nightwatchjs/nightwatch/releases/tag/v2.5.4 doesn't appear to indicate that the issue we're seeing here has been resolved though.
Comment #14
longwaveComment #15
longwaveNot very hopeful, given the lack of movement on the GitHub issue linked above, but let's try Nightwatch 2.6.19.
Comment #16
smustgrave commentedSeems those updates caused the chromedriver to not connect
https://dispatcher.drupalci.org/job/drupal_patches/175960/console
Comment #17
wim leersSince #15, https://github.com/nightwatchjs/nightwatch/releases/tag/v2.6.20 was released, but I don't see anything in the release notes that sounds like it would help fix the failure we observed.
Comment #19
longwaveWorking in #3371963: Update Nightwatch to 3.x instead, will transfer credit.
Comment #20
quietone commentedRestoring version.