The output of ChromeDriverManager().install()
is an executable_path
to the driver, but executable_path
was removed in selenium
4.10.0
. That's why you're seeing the error after passing the value into webdriver.Chrome()
. Here are the changes:
https://github.com/SeleniumHQ/selenium/commit/9f5801c82fb3be3d5850707c46c3f8176e3ccd8e
Note that executable_path
was removed. If you want to pass in an executable_path
, you'll have to use the service
arg now. (service=Service(executable_path='./chromedriver')
) But Selenium Manager is now fully included with selenium
4.10.0
, so this is all you need:
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 for you.