Selenium and Chrome For Testing, how to disable the new browser.driver download?
I have Chrome For Testing and chromedriver installed in a custom location, and everything works, but it downloads the newer version(and does nothing with them everytime I run the script.)
I can watch in task manager as it maxes out my internet for a while downloading.
service = Service()
options = webdriver.ChromeOptions()
chrome_path = r"testingchrome-win64chrome.exe"
options.binary_location = chrome_path
#options.page_load_strategy = 'eager'
#options.add_argument("--headless=new")
options.add_experimental_option('excludeSwitches', ['enable-logging'])
#options.add_experimental_option("detach", True)
options.add_argument("disable-extensions");
options.add_experimental_option("prefs", {
"download.default_directory": "my\directory",
"download.prompt_for_download": False,
"download.directory_upgrade": True,
"credentials_enable_service": False,
"profile.password_manager_enabled": False,
})
Service('testing/driver/chromedriver.exe')
driver = webdriver.Chrome(service=service, options=options)
driver.get('https://www.google.com/')
Here is the log-
Selenium Manager set by env SE_MANAGER_PATH to: C:******Scriptsselenium-manager.exe
Selenium Manager binary found at: C:*******Scriptsselenium-manager.exe
Executing process: C:******Scriptsselenium-manager.exe --browser chrome --browser-path testingchrome-win64chrome.exe --debug --language-binding python --output json
chromedriver not found in PATH
Running command: wmic datafile where name='C:******\testing\chrome-win64\chrome.exe' get Version /value
Output: ""
Running command: REG QUERY HKCUSoftwareGoogleChromeBLBeacon /v version
Output: ""
chrome not found in the system
Required browser: chrome 126.0.6478.182
chrome 126.0.6478.182 already exists
chrome 126.0.6478.182 is available at C:******.cacheseleniumchromewin64126.0.6478.182chrome.exe
Required driver: chromedriver 126.0.6478.182
chromedriver 126.0.6478.182 already in the cache
Driver path: C:******.cacheseleniumchromedriverwin64126.0.6478.182chromedriver.exe
I do have the chrome 126.0.6478.183 (just updated) as my normal browser, the CFT is in a seperate location.
Name: selenium
Version: 4.22.0
CFT Version 126.0.6478.182