-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
[🐛 Bug]: Couldn't find a matching Chrome browser for tag ${tag} on platform ${platform} #10968
Comments
@jacekcho are you behind a corporate proxy? |
Yes, we use proxy.
The same issue is on the gitlab
My bad. Not proxy but vpn...
…On Fri, 18 Aug 2023, 17:07 Christian Bromann, ***@***.***> wrote:
@jacekcho <https://github.com/jacekcho> are you behind a corporate proxy?
—
Reply to this email directly, view it on GitHub
<#10968 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AFVCQ7MFLQEL7RD6QQXDMG3XV6AKHANCNFSM6AAAAAA3VMHUTE>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Can you try setting |
Sorry my bad... We use vpn not proxy... |
What does that mean? Can you guarantee that your Node.js environment can access the internet? |
Yes, I can confirm that. until today we used selenium-standalone-servrer and wdio 7. but after today update to chrome 116 chromedriver version 114 stopped working so i wanted to update the project to wdio 8 and remove selenium standalone server |
I have the same issue on my Mac(M1) but once I got off the VPN it started working. Also, I'm not sure why my webdriver is trying to use chromedriver v.118 when I pinned my chromedriver to v.115? |
How did you pinned your Chromedriver? |
as one of the devDependencies in package.json |
@sumanthpfs if you use latest WebdriverIO this package won't be used anymore. Instead you can define in your capabilities the Chrome browser version, read more on this in the docs: https://webdriver.io/docs/capabilities#automate-different-browser-channels |
@christian-bromann setting the browser version according to the new approach for wdio8 will start an attempt to download it, which will end with the error described in this thread: I did some tests and I confirm that for wdio-7 launching the browser with usage: works fine (tests run and everything works) it seems that in some cases the chromedriver download mechanism used for wdio8 doesn't work properly... |
I was under the assumption it only takes the Chrome browser version and not the chromedriver version but I got it now, thanks. |
My team is running into this as well. However, with the exact same code base the people using a mac run into it while I'm not having this issue running this in windows. Once we had them turn off the ZScaler Internet Security it was able to start working for them. So that would be a similar issue as the VPN issue @sumanthpfs ran into. |
To sum up (and adding more logs) running locally in my case I get the error:
running on gitlab fails with an error:
|
@jacekcho If you test
I am not sure where this error comes from, I raised an issue in the upstream dependency. |
Upgrading to the latest webdriverio is giving me this same error. I'm on a corporate VPN as well. I never had any issues the old way doing
|
@tkmcmaster Can you try setting |
As far as I can tell, from a browser it's all "DIRECT" for the proxy. Even turning on logging (chrome://net-export/) I get "direct". I tried everything from https://superuser.com/questions/346372/how-do-i-know-what-proxy-server-im-using. I'm using Ubuntu 20.04 on WSL/Windows 10 but it's failing on both Windows and on WSL.
|
https://googlechromelabs.github.io/chrome-for-testing/known-good-versions.json |
You are right, thanks! i was checking the normal chrome versions not the testing ones. Is there any way to make webdriverio completely ignore the download of the driver? im being forced to use v8.13.0 to avoid all these changes (before i was just using the binary option not setting up a driver), would be good to have a flag since i for instance don't need any of this but im being forced to (maybe there is but i couldn't find it). |
Yes, once you have a |
Thanks for the response! So i read about those 2 properties in the docs but is not exactly what i need, and i am sorry if this is not the place to ask this we can move it to other issue, but basically this is an electron-cordova app and we are not running a selenium-grid (which i believe its what hostname and port is for?), been testing it for 2 years with webdriverio with no issues, first i used my own capabilities, then migrated to the wdio-electron-service and now im back to my own capabilites (im doing some testing on how this works and want to get the basics working once again) but wdio its forcing me to install a chromedriver (which is not necessary for testing the app). Im following the basic setup from electron page here: https://www.electronjs.org/es/docs/latest/tutorial/automated-testing so im using this: export.config = {
// ...
capabilities: [{
browserName: 'chrome',
'goog:chromeOptions': {
binary: '/path/to/your/electron/binary', // Path to my electron compiled app (.exe or equivalent in linux).
args: [/* cli arguments */] // Optional, perhaps 'app=' + /path/to/your/app/
}
}]
// ...
} With this configuration you don't need the chromedriver as far as im concerned and this is an advantage because it allows to bypass this issue that has been open more than a year in their repo here: electron/electron#33942 and also here in the selenium repo: SeleniumHQ/selenium#4504 So basically, we have a lot of code that works with funcitons like this: browser.setWindowSize(1920, 1080) // this crashes if we setup a chromedriver
element.scrollIntoView() // This also crashes Maybe i understood wrong how port and hostname work, but when i set either it does not start because the hostname is invalid (setting localhost) which i assume is correct because i have no grid. Thanks for the fast response and sorry if this is not the appropiate place! |
Why you stopped using the electron service? It is well maintained but currently also having issue with the driver manager (webdriverio-community/wdio-electron-service#167)
I will take a look and ensure that Chrome is not being downloaded if you provide a binary path. However you need Chromedriver to control the Electron app. |
@sunkarabhargava @jacekcho are you both using latest WebdriverIO? |
Yes i use latest wdio
package.json:
|
Hello @christian-bromann , I've utilized all the latest versions of wdio packages. I encountered this issue while using capabilities with 'browserVersion' for Chrome. By default, it was utilizing an older ChromeDriver 8.xx. To ensure the use of the latest one, I employed 'browserVersion: stable'. However, this led to failures as I mentioned above. I discovered a workaround: by adding 'npm config set strict-ssl false' in npmrc and setting 'NODE_TLS_REJECT_UNAUTHORIZED=0' in the env, along with adding 'acceptInsecureCerts: true' in capabilities. This workaround worked, but only until I restarted the system. After a restart, even though the previously downloaded ChromeDriver and Chrome were present, the same issue persisted. To proceed with my work, I opted to delete them and repeat the steps mentioned earlier. |
Its a really odd issue because - we have 2 identical build pipelines in Azure DevOps - one using node v16 and one using node v20. - both using ubuntu agents. The pipeline using node v16 is fine but we get the error on the node v20 pipeline. I cannot work out why... in our config we have:
The error we see on the node v20 pipeline is:
In our node v16 pipeline which works, logs are:
|
@simonDominos Were you able to find a solution to this? I am running into the same issue.
|
I ended up using the workaround from #11105 (comment) and specify the binary path via environment variable to test locally. The issue doesn't seem to happen when not on VPN (or in Github Actions). I had to leave the capabilities: [{
browserName: "chrome",
"goog:chromeOptions": {
binary: process.env.CHROME_PATH,
...
},
"wdio:chromedriverOptions": {
binary: process.env.CHROME_PATH
},
...
}],
...
services: [
"chromedriver",
... |
I've also been trying to resolve issues with the automatic chromedriver download. I didn't get this error, instead I was getting an immediate ETIMEDOUT which I'm almost certain is proxy related. While investigating, I noticed that the chromedriver package attempts a similar download and that works fine! In the output I noticed a comment about using a workaround for an https url combined with a proxy. See this block of code in the install script. Since this chromedriver package had no issue downloading/installing the chromedriver executable and involves certificate authority configuration, I imagine this is a missing step to support automatic driver download from behind a corporate proxy. |
@kyle-blair thanks for this investigation. It seems like Chromedriver did use the NPM certificate when setting Proxy settings. |
@kyle-blair can you verify that you have a value returned when running this NPM script: "x": "node -e \"console.log(process.env.npm_config_ca, process.env.npm_config_cafile)\"" run via |
@christian-bromann that script returns |
A co-worker had the same problem. We rolled back to a 7 version of wdio, and his problem went away. |
For some reason the automatic Chromedriver download only works for me after adding the proxy to my .npmrc: Setting the proxy as an Environment Variable - which is normally enough - did not help! WDIO version is 8.16.20 |
I'm regularly seeing this error as an inconsistent flake locally and in CI and in both cases there's no http proxy involved - it is downloading (or at least attempting to download) directly.
I tried replacing latest with stable or a hardcoded version and I get the same. I hacked this file in my node_modules and ran again to get some debug output: https://github.com/puppeteer/puppeteer/blob/84ad6de2e6d292771cc66523ec7ae91f65281a91/packages/browsers/src/httpUtil.ts#L27 ie.
and I get this:
But if I go here manually it works: https://googlechromelabs.github.io/chrome-for-testing/#stable If I try I get:
|
I'm running in the same issue on CI/CD process (there is no proxy or VPN configured):
|
I started getting this locally as well (in the MacBook), and If I comment the browserVersion, I got this error:
my webdriverIO version is:
It looks like the link the webdriverIO is trying to download the binary is not working (tried to access it manually). |
Looks like it is this: #12251 this @puppeteer/browsers PR puppeteer/puppeteer#11923 but webdriverio hasn't had a new release yet. |
thanks so much! |
oh there's also #12305 |
Yes, the issue should be resolved now. Let me know if it isn't. |
@christian-bromann I'm seeing the same issue for Firefox on M1 with 8.32.2
|
this workaround resolved the issue for me #12251
|
I will go ahead and close the issue since there hasn't been any new development to the problem since last October. If you update to latest WebdriverIO v8 you should have no issues setting up browser and driver in WebdriverIO. If you experience problems, please raise a new issue with a reproducible example. Thanks! |
I'm fighting with this issue with every Chrome update. e.g. https://edgedl.me.gvt1.com/edgedl/chrome/chrome-for-testing/122.0.6261.69/mac-arm64/chromedriver-mac-arm64.zip was not available when this comment has been written. Then I have to download the chromedriver manually from: |
@wolfoo2931 if your WebdriverIO version still attempts to download from the |
Seems to work. Thank you for fixing and the notification. |
Have you read the Contributing Guidelines on issues?
WebdriverIO Version
latest
Node.js Version
16
Mode
Standalone Mode
Which capabilities are you using?
What happened?
tests are not run, an error is displayed: Couldn't find a matching Chrome browser for tag "116.0.5845.96" on platform "mac_arm"
This error is showing on my machine (and other members of my team on linux/intel mac/Mac M1) for a project that was generated according to: https://webdriver.io/docs/gettingstarted
npm init wdio .
package.json:
package.txt
wdio.conf.js:
wdio_conf.txt
What is your expected behavior?
The chromedriver is downloaded and the browser is launched
How to reproduce the bug.
create a new project:
npm init wdio .
Installing @wdio/cli to initialize project...
✔ Success!
===============================
🤖 WDIO Configuration Wizard 🧙
? What type of testing would you like to do? E2E Testing - of Web or Mobile Applications
? Where is your automation backend located? On my local machine
? Which environment you would like to automate? Web - web applications in the browser
? With which browser should we start? Chrome
? Which framework do you want to use? Mocha (https://mochajs.org/)
? Do you want to use a compiler? Babel (https://babeljs.io/)
? Do you want WebdriverIO to autogenerate some test files? Yes
? Where should these files be located? /Users/user/workspace/tmp/wdio-tmp--v8/test/specs//*.js
? Do you want to use page objects (https://martinfowler.com/bliki/PageObject.html)? Yes
? Where are your page objects located? /Users/user/workspace/tmp/wdio-tmp--v8/test/pageobjects//*.js
? Which reporter do you want to use? spec
? Do you want to add a plugin to your test setup? wait-for
? Do you want to add a service to your test setup?
? What is the base url? http://localhost
? Do you want me to run
npm install
YesSetting up Babel project...
✔ Success!
Installing wdio packages:
added 226 packages, and audited 754 packages in 11s
103 packages are looking for funding
run
npm fund
for detailsfound 0 vulnerabilities
✔ Success!
Creating a WebdriverIO config file...
✔ Success!
Autogenerating test files...
✔ Success!
Adding "wdio" script to package.json.
✔ Success!
🤖 Successfully setup project at /Users/user/workspace/tmp/wdio-tmp--v8 🎉
Relevant log output
Code of Conduct
Is there an existing issue for this?
The text was updated successfully, but these errors were encountered: