from selenium import webdriver
from selenium.webdriver.chrome.options import Options
options = Options()
options.binary_location = "C:/Program Files (x86)/Google/Chrome/Application/chrome.exe"
driver = webdriver.Chrome(chrome_options=options, executable_path="C:/Utility/BrowserDrivers/chromedriver.exe", )
driver.get('http://google.com/')
Above is my code, but when I try to run it I am getting the chrome_options error. Could anyone please help me in resolving this?
webdriver.Chrome constructor doesn't have the 'chrome_options' parameter anymore. It has been deprecated, and now you have to use the 'options' parameter.
Also, the executable_path has been deprecated. Check this post
Here's Chrome class in Selenium4: