I have researched a lot and used many possible solutions mentioned in the various forums, none of them worked for me. I am trying to run this in CI/CD pipeline although able to run the protractor test cases in local and able to launch the browser but in CI/CD pipeline build it is failing below are the details the issue occurs for protractor 2.5.4 E/launcher - session not created: This version of ChromeDriver only supports Chrome version 79
i am using below postinstall under scripts in package.json
"postinstall": "npm uninstall -g webdriver-manager protractor && npm install -g webdriver-manager protractor && webdriver-manager update && cd ./node_modules/protractor && npm i webdriver-manager@latest",
"postinstall": "cd ./node_modules/protractor && npm i webdriver-manager@latest",
for the above script command below error is thrown I/file_manager - creating folder D:\a\1\s\node_modules\protractor\node_modules\webdriver-manager\selenium I/config_source - curl -oD:\a\1\s\node_modules\protractor\node_modules\webdriver-manager\selenium\chrome-response.xml https://chromedriver.storage.googleapis.com/ I/downloader - curl -oD:\a\1\s\node_modules\protractor\node_modules\webdriver-manager\selenium/chromedriver_79.0.3945.36.zip https://chromedriver.storage.googleapis.com/79.0.3945.16/chromedriver_win32.zip I/update - chromedriver: unzipping chromedriver_79.0.3945.36.zip I/launcher - Running 1 instances of WebDriver I/direct - Using ChromeDriver directly... E/launcher - session not created: This version of ChromeDriver only supports Chrome version 79 when i use below script command i get version issue for 76
"postinstall": "webdriver-manager update"
I/update - chromedriver: file exists D:\a\1\s\node_modules\protractor\node_modules\webdriver-manager\selenium\chromedriver_76.0.3809.12.zip I/update - chromedriver: unzipping chromedriver_76.0.3809.12.zip I/update - chromedriver: chromedriver_76.0.3809.12.exe up to date I/launcher - Running 1 instances of WebDriver I/direct - Using ChromeDriver directly... E/launcher - session not created: This version of ChromeDriver only supports Chrome version 76 (Driver info: chromedriver=76.0.3809.12 below is config.json under webdriver-manager
{
"webdriverVersions": {
"selenium": "2.53.1",
"chromedriver": "2.27",
"maxChromedriver": "77",
"geckodriver": "v0.13.0",
"iedriver": "2.53.1",
"androidsdk": "24.4.1",
"appium": "1.6.5"
},
"cdnUrls": {
"selenium": "https://selenium-release.storage.googleapis.com/",
"chromedriver": "https://chromedriver.storage.googleapis.com/",
"geckodriver": "https://github.com/mozilla/geckodriver/releases/download/",
"iedriver": "https://selenium-release.storage.googleapis.com/",
"androidsdk": "http://dl.google.com/android/"
}
}
Tried many commands that might get worked on the pipeline build but none of them is helping me out. Can any one please suggest what could be the possible issue.
The below should work (tested on Mac).
npx webdriver-manager update --versions.chrome=$(/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --version | cut -d ' ' -f 3)
please mention the version and try to download the chromedriver.
For eg, if chorme version is 79
webdriver-manager update --versions.chrome 79.0.3945.36
If the version is 76,
webdriver-manager update --versions.chrome 76.0.3809.68
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With