Selenium WebDriver Chrome 115 Compatibility Issues
Problem Statement
Starting July 2023, users encountered ValueError: There is no such driver by url
when using Selenium with Chrome 115+. This occurs because the Chromium team restructured ChromeDriver releases. Traditional ChromeDriver download endpoints (chromedriver.storage.googleapis.com
) only support up to version 114. Chrome 115+ drivers are exclusively distributed through the new "Chrome for Testing" initiative. Attempts to solve this by disabling Chrome updates or downgrading to v114 are temporary workarounds, as Chrome auto-updates cannot be reliably disabled.
Recommended Solutions
✔️ Solution 1: Use Built-in Selenium Manager (Best Practice)
Selenium 4.10.0+ includes Selenium Manager, which automatically handles driver compatibility. Remove third-party dependencies and simplify your code:
pip install selenium==4.10.0
from selenium import webdriver
from selenium.webdriver.chrome.service import Service
service = Service()
options = webdriver.ChromeOptions()
driver = webdriver.Chrome(service=service, options=options)
driver.get("https://example.com")
driver.quit()
- How It Works: Selenium Manager detects your Chrome version and downloads the matching driver from the official Chrome for Testing repository
- Advantages: No external dependencies; handles future Chrome updates automatically
✔️ Solution 2: Update webdriver-manager Package
If you must use webdriver-manager
, upgrade to v3.8.6+ for Chrome 115+ compatibility:
pip install --upgrade webdriver-manager
from selenium.webdriver.chrome.service import Service
from webdriver_manager.chrome import ChromeDriverManager
service = Service(ChromeDriverManager().install())
✔️ Solution 3: Manual Chrome for Testing Setup
For restricted environments or advanced control:
- Find the stable build version:bash
curl https://googlechromelabs.github.io/chrome-for-testing/LATEST_RELEASE_STABLE # Returns version like "115.0.5790.99"
- Download Chrome and ChromeDriver (replace
$VERSION
with actual version):bashVERSION="115.0.5790.99" curl -O "https://storage.googleapis.com/chrome-for-testing-public/$VERSION/linux64/chromedriver-linux64.zip" curl -O "https://storage.googleapis.com/chrome-for-testing-public/$VERSION/linux64/chrome-linux64.zip" unzip chromedriver-linux64.zip -d /opt/chromedriver unzip chrome-linux64.zip -d /opt/chrome
- Point Selenium to the binaries:python
from selenium.webdriver.chrome.service import Service from selenium.webdriver.chrome.options import Options options = Options() options.binary_location = "/opt/chrome/chrome-linux64/chrome" service = Service("/opt/chromedriver/chromedriver-linux64/chromedriver") driver = webdriver.Chrome(service=service, options=options)
Why This Happened
Chrome 115+ moved to the Chrome for Testing distribution model. Key changes:
- Traditional endpoints (
chromedriver.chromium.org
) only serve v114 and older - Newer versions require ChromeDriver binaries from the CfT repository
- Selenium's native tools and updated packages now reference this new source
Compatibility Note
Always match major Chrome and ChromeDriver versions (e.g., Chrome 115.x requires ChromeDriver 115.x). Mismatched versions cause initialization failures.
Temporary Workarounds (Not Recommended)
These solutions create maintenance overhead and should be avoided:
# Downgrade to Chrome/Driver v114 (fragile)
service = Service(ChromeDriverManager(version="114.0.5735.90").install())
# Switch to Firefox (not always feasible)
driver = webdriver.Firefox()
Best Practice Summary
- Upgrade Selenium to v4.10.0+ and use its built-in manager
- Verify environment consistency with:python
print("Browser:", driver.capabilities['browserVersion']) print("Driver:", driver.capabilities['chrome']['chromedriverVersion'].split(' ')[0])
- If using
webdriver-manager
, ensure it's v3.8.6+ - For Docker/k8s environments, use the provided Bash scripts to install CfT binaries
Deprecated Approach Avoidance
Do not attempt to disable Chrome updates or force legacy version downloads—these are unreliable and break automatically.