Unable to download chrome driver for version 115
Asked Answered
R

14

22

I am unable to download the Chrome driver for Chrome version 115. I have downloaded the ZIP file from:

https://edgedl.me.gvt1.com/edgedl/chrome/chrome-for-testing/115.0.5790.102/win64/chrome-win64.zip

But I am unable to find the chromedriver.exe file there.

I am running a Java-Selenium test which needs the chromedriver path. I copied the path of chrome.exe into the program, but it's failing and giving the error as Timed out waiting for driver server to start. Do I need chromedriver.exe for this? And how can I get this?

Remus answered 23/7, 2023 at 6:48 Comment(4)
Looks like you downloaded Chrome (browser) zip and not the chromedriver one. I got caught for this as well.Tantalate
This helped me -> Webdrivers trying to load a Chrome version that doesn't exist #247 github.com/titusfortner/webdrivers/issues/247Frankenstein
How reputable is edgedl.me.gvt1.com?Malta
On Windows, presumably?Malta
O
12

Use chrome driver version 114.0.5735.90 for chrome version 115. It's working for me.

Octillion answered 27/7, 2023 at 9:49 Comment(1)
this is the easiest fix. Thank youFully
H
8

Use the new chromedriver download site: https://googlechromelabs.github.io/chrome-for-testing/#stable

The URL under chromedriver for win32 holds a chromedriver.exe which you have to unpack and add to your path. Both chromedriver and Google Chrome of the same version (115) must be found in path by Selenium to work.

Hamner answered 23/7, 2023 at 6:53 Comment(0)
B
6

Just in case, someone is downloading programmatically in Docker.

So I had a situation, where

  • I had latest chrome stable in my Dockerfile
  • Using the major version from the google-chrome, I had to find out the right URL to use for downloading its corresponding chromedriver. Earlier you could use the link https://chromedriver.storage.googleapis.com/LATEST_RELEASE_${CHROME_MAJOR_VERSION} to get the latest full version, and then it was straightforward to download when you have the full version.

Now, I am using the JSON APIs from the suggested chrome-for-testing repository, and finding the URL in it using jq to match for major version and platform.

curl --silent "https://googlechromelabs.github.io/chrome-for-testing/last-known-good-versions-with-downloads.json" \
  | jq --arg majorVersion "$CHROME_MAJOR_VERSION" -r '.channels.Stable | select(.version | startswith($majorVersion | tostring)).downloads.chromedriver[] | select(.platform == "linux64") | .url' \
  | xargs curl -L --show-error --silent --output chromedriver-linux64.zip
Bring answered 27/7, 2023 at 16:30 Comment(0)
C
3

Here is the link to the chromedriver for 115 version: https://edgedl.me.gvt1.com/edgedl/chrome/chrome-for-testing/115.0.5790.102/win32/chromedriver-win32.zip

Certify answered 25/7, 2023 at 9:15 Comment(0)
S
3

The solution is really easy for this one. Use Selenium 4.10.0.

We were using WebDriverManager for driver management and since Chrome updated to version 115, WebDriverManager was unable to find the new chromedriver due to the change in the URL.

We simply removed WebDriverManager and let Selenium Manager handle the drivers, and it is now working perfectly fine.

One thing to note is that Selenium is downloading chromedriver 114 for Chrome 115. But at least we are not blocked anymore.

Superlative answered 27/7, 2023 at 6:9 Comment(0)
P
3

To install the latest Chrome and Chromedriver in Docker:

# Install latest Chrome
RUN CHROME_URL=$(curl -s https://googlechromelabs.github.io/chrome-for-testing/last-known-good-versions-with-downloads.json | jq -r '.channels.Stable.downloads.chrome[] | select(.platform == "linux64") | .url') \
    && curl -sSLf --retry 3 --output /tmp/chrome-linux64.zip "$CHROME_URL" \
    && unzip /tmp/chrome-linux64.zip -d /opt \
    && ln -s /opt/chrome-linux64/chrome /usr/local/bin/chrome \
    && rm /tmp/chrome-linux64.zip

# Install latest chromedriver
RUN CHROMEDRIVER_URL=$(curl -s https://googlechromelabs.github.io/chrome-for-testing/last-known-good-versions-with-downloads.json | jq -r '.channels.Stable.downloads.chromedriver[] | select(.platform == "linux64") | .url') \
    && curl -sSLf --retry 3 --output /tmp/chromedriver-linux64.zip "$CHROMEDRIVER_URL" \
    && unzip -o /tmp/chromedriver-linux64.zip -d /tmp \
    && rm -rf /tmp/chromedriver-linux64.zip \
    && mv -f /tmp/chromedriver-linux64/chromedriver "/usr/local/bin/chromedriver" \
    && chmod +x "/usr/local/bin/chromedriver"

According to https://chromedriver.chromium.org/downloads/version-selection as of version 115 Google has changed the release process for Chrome and Chromedriver. There are multiple JSON endpoints that you can probe for latest stable version of both Chrome and Chromedriver.

Puritanism answered 20/8, 2023 at 2:27 Comment(0)
C
1

Selenium Manager is now fully included with selenium 4.10.0, so this is all you need (for Python):

from selenium import webdriver
from selenium.webdriver.chrome.service import Service

service = Service()
options = webdriver.ChromeOptions()
driver = webdriver.Chrome(service=service, options=options)
# ...
driver.quit()

If the driver isn't found on your system PATH, Selenium Manager will automatically download it.

You can also find a specific driver for a particular milestone with this endpoint: https://googlechromelabs.github.io/chrome-for-testing/latest-versions-per-milestone-with-downloads.json


If you're wondering why you're now seeing this error for ChromeDriverManager, it's because https://chromedriver.chromium.org/downloads only goes up to version 114 due to driver restructuring by the Chromium Team for the new Chrome-for-Testing.

Chin answered 26/7, 2023 at 19:45 Comment(2)
Can you please clarify where this download will be saved on the system?Impaste
Selenium saves drivers to ~/.cache/selenium/Chin
P
1

If you look at the ChromeDriver - WebDriver for Chrome - Downloads page you will find the last version of ChromeDriver to be published was ChromeDriver 114.0.5735.90.

So if you are using Chrome version 115 or newer you have to check the Chrome for Testing availability dashboard which provides convenient JSON endpoints for specific ChromeDriver version downloading.


Selenium Manager

With the availability of Selenium v4.6 and above you don't need to explicitly download ChromeDriver, GeckoDriver or any browser drivers as such using webdriver_manager. You just need to ensure that the desired browser client i.e. , or is installed.

Selenium Manager is the new tool integrated with that would help to get a working webdriver version to run Selenium out of the box. Beta 1 of Selenium Manager will configure the browser drivers for Chrome, Firefox, and Edge if they are not present on the PATH.


Solution

As a solution you can simply do:

from selenium import webdriver

driver = webdriver.Chrome()
driver.get("https://www.google.com/")

tl; dr

Chrome for Testing: reliable downloads for browser automation

Pendergrass answered 29/7, 2023 at 19:0 Comment(0)
D
0

I am finding the same on macOS.

selenium-webdriver 4.10.0, which never changed.

My Chrome is up-to-date and is in the same path. So this seems to be with a recent version of Selenium.

Decline answered 28/7, 2023 at 15:14 Comment(0)
U
0

The solution is really easy for this one. Use Selenium 4.9.0. stable version.

In this version, there isn't any need to download the chromedriver.exe file. In this version, Selenium Manager handles the drivers, and it is now working perfectly fine.

Uela answered 28/7, 2023 at 15:23 Comment(0)
O
0

You can check if Selenium Manager finds your browser and the driver correctly with:

$ ./VS/packages/Selenium.WebDriver.4.11.0/manager/windows/selenium-manager.exe --browser chrome
INFO    Driver path: C:\%USER%\.cache\selenium\chromedriver\win64\115.0.5790.170\chromedriver.exe
INFO    Browser path: C:\Program Files\Google\Chrome\Application\chrome.exe

This is the output from my development environment, but on the runners this didn't work and the automatic download failed, because those URLs are blocked on my companies network:

For chrome, if you are using Selenium.WebDriver.ChromeDriver then you just need to add this packages drivers to your PATH and the above command should find the driver. Additionally, you need to install the correct browser version compatible with the driver.

Ophthalmitis answered 3/8, 2023 at 12:49 Comment(0)
C
0

Try using the link for win32 instead of win64. win32 contains the Chromedriver and will solve your issue.

Cyndicyndia answered 18/8, 2023 at 13:10 Comment(1)
Your answer could be improved with additional supporting information. Please edit to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers in the help center.Wulf
M
0

The links for both Chrome and chromedriver versions can be found here (in a JSON friendly format, not user friendly). You'll need to expand the nodes to search for the specific version

Mono answered 11/10, 2023 at 11:54 Comment(0)
O
-1

If you use the 4.10.0 Selenium version then this issue will not come. But for the chrome binary issue, this link will help:

Issue

org.openqa.selenium.WebDriverException: unknown error: cannot find Chrome binary

Currently, there was some change announced by Chromedriver. Here are the complete details. After that, So many issues are coming.

Solution

Below is the quick fix for Mac users (Who are using Selenium 4.10.0)

ChromeOptions options = new ChromeOptions();
options.setBinary("/Applications/Google Chrome.app/Contents/MacOS/Google Chrome");
WebDriver driver = new ChromeDriver(options);

In Mac, machine error is due to the binary. After specifying the binary path this will work!!

Oldcastle answered 26/7, 2023 at 19:50 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.