Chrome 一些信息:
解决过程:
from selenium import webdriver
from selenium.webdriver.chrome.options import Options
def test_xxx():
chrome_options = Options()
# 关闭使用 ChromeDriver 打开浏览器时上部提示语 "Chrome正在受到自动软件的控制"
chrome_options.add_argument("disable-infobars")
# 允许浏览器重定向,Framebusting requires same-origin or a user gesture
chrome_options.add_argument("disable-web-security")
driver = webdriver.Chrome(chrome_options=chrome_options)