首页 > 解决方案 > webdriver.Chrome(ChromeDriverManager().install(), options=options) 给出错误:SSLCertVerificationError

问题描述

我是 Selenium Python 的新手,我正在尝试执行以下操作,我收到错误为“requests.exceptions.SSLError: HTTPSConnectionPool(host='chromedriver.storage.googleapis.com', port=443): Max retries exceeded with url:/LATEST_RELEASE_93.0.4577(由 SSLError(SSLCertVerificationError(1,'[SSL: CERTIFICATE_VERIFY_FAILED] 证书验证失败:无法获取本地颁发者证书(_ssl.c:1129)'))“请让我知道我该怎么做必须做些什么才能通过这个错误?

from webdriver_manager.chrome import ChromeDriverManager
options = webdriver.ChromeOptions()
options.headless = False
options.add_argument('--incognito')
options.add_argument('--allow-running-insecure-content')
options.add_argument('--ignore-certificate-errors')
webdriver.Chrome(ChromeDriverManager().install(), options=options)
driver = webdriver.Chrome()

标签: python-3.xseleniumselenium-webdriver

解决方案


推荐阅读