Selenium+Python 解决Chrome正在受到自动软件的控制的办法(V78版本有效)

from selenium import webdriver
option = webdriver.ChromeOptions()
option.add_experimental_option('useAutomationExtension', False)
option.add_experimental_option("excludeSwitches", ['enable-automation'])
browser = webdriver.Chrome(r'd:\chromedriver.exe',chrome_options=option)
url = "https://toefl.neea.cn/login"
browser.get(url)

此方法针对V78版本及以上有效,同时可以解决部分网站白屏的问题。

发布了53 篇原创文章 · 获赞 47 · 访问量 46万+

猜你喜欢

转载自blog.csdn.net/ryu2003/article/details/103407797