谷歌浏览器版本在V75以及以下解决办法如下:
from selenium import webdriver optons = webdriver.ChromeOptions() optons.add_argument('disable-infobars') driver = webdriver.Chrome(options=optons) driver.maximize_window() driver.get("")
谷歌浏览器版本在V76以及以上解决办法如下:
from selenium import webdriver option = webdriver.ChromeOptions() option.add_experimental_option('useAutomationExtension', False) option.add_experimental_option('excludeSwitches', ['enable-automation']) driver = webdriver.Chrome(options=option) driver.get("")