Problem while running on Mac with an M4 chip
Preliminary checklist
- [x] I am using the latest stable version of DDEV
- [x] I am using the latest stable version of this add-on
Expected Behavior
A session gets created
Actual Behavior
Error 500
Steps To Reproduce
I'm using a MacBook Pro m4
Os 15.3.1 ddev version v1.24.7 And version 2.0 of this add-on
While running this test: :/var/www/html/web/core$ yarn test:nightwatch tests/Drupal/Nightwatch/Tests/langcodeTest.js
I keep getting this error:
[Tests/Langcode Test] Test Suite
────────────────────────────────────────────────────────────────
⠋ Connecting to selenium-chrome on port 4444...
Error
Response 500 POST http://selenium-chrome:4444/wd/hub/session (49ms)
{
value: {
error: 'session not created',
message: 'Could not start a new session. Error while creating session with the driver service. Stopping driver service: Could not start a new session. Handshake response does not match any supported protocol. Response payload: {"sessionId":"e550e4f286f365c8cc20dacc82f5e002","status":33,"value":{"message":"session not created: Missing or invalid capabilities\\n (Driver info: chromedriver=138.0.7204.183 (e90faf484ddbc033fc9bf337621761d3dd5c5289-refs/branch-heads/7204@{#2435}),platform=Linux 6.10.14-linuxkit aarch64)"}} \n' +
"Host info: host: '4cd9f41baa94', ip: '172.19.0.3'\n" +
"Build info: version: '4.34.0', revision: '2a4c61c498'\n" +
"System info: os.name: 'Linux', os.arch: 'aarch64', os.version: '6.10.14-linuxkit', java.version: '21.0.8'\n" +
'Driver info: driver.version: unknown\n' +
"Build info: version: '4.34.0', revision: '2a4c61c498'\n" +
"System info: os.name: 'Linux', os.arch: 'aarch64', os.version: '6.10.14-linuxkit', java.version: '21.0.8'\n" +
'Driver info: driver.version: unknown',
stacktrace: ''
}
⚠ Failed to connect to Selenium Server on selenium-chrome with port 4444.
Does anybody have a clue how I can get this to run?
Anything else?
No response
The key info is this:
Missing or invalid capabilities\n (Driver info: chromedriver=138.0.7204.183 (e90faf484ddbc033fc9bf337621761d3dd5c5289-refs/branch-heads/7204@{#2435}),platform=Linux 6.10.14-linuxkit aarch64)"}
Please provide the output of ddev debug test (consider a gist, or attach as a text file), thanks.
- Your project does not seem to have this add-on installed, but does seem to have some weird corrupted info there? Consider uninstalling all add-ons and reinstalling,
- [unrelated] I don't see why you have
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/master/install.shsince nvm is built into DDEV (but deprecated in favor of nodejs_version)
But ddev add-on list --installed should sure show the exact add-ons you have installed (including this one).
I doubt your problem has anything to do with "Mac with M4 chip", please update the title as you learn more.
Yes, it might be something else but when I change docker-compose.selenium-chrome.yaml
from
services: selenium-chrome: image: selenium/standalone-chromium:138.0
to:
selenium-chrome: image: seleniarm/standalone-chromium:4.1.4-20220429
And run ddev restart
then I can run those tests without error. That indicates to me that the image is the problem.
I think you'll find other issues here about that change, and it sounds like you have a solution. But... to get support, please use the actual add-on and have clean add-on setup. ddev add-on list --installed should show you exactly the add-ons you're intending to use (including this one). I recommend removing all until you have none, then do a git status and make sure you're clean, then do the ddev add-on get ... for each you want again.
I did some spring (fall) cleaning and removed all addons and added this one. I still have the same problem. I attached the new file from the ddev debug test process.
For now I am going to stick to selenium-chrome: image: seleniarm/standalone-chromium:4.1.4-20220429 and check new images when they arrive. I checked newer images from seleniarm/standalone-chromium and no luck yet.
@rfay thanks for your help!
That does look a lot better!
To override an add-on provided configuration, use a docker-compose.selenium-standalone-chrome_extra.yaml rather than editing the add-on provided file.