urllib.error.URLError: urlopen error [SSL: CERTIFICATE_VERIFY_FAILED]

简介: urllib.error.URLError: urlopen error [SSL: CERTIFICATE_VERIFY_FAILED]

报错

urllib.error.URLError: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:833)>

解决方法

# 全局取消证书验证
import ssl
ssl._create_default_https_context = ssl._create_unverified_context

参考

Python [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed 解决方法

相关文章
|
3月前
|
JavaScript
request to https://registry.npm.taobao.org/cnpm failed, reason: certificate has expired
request to https://registry.npm.taobao.org/cnpm failed, reason: certificate has expired
91 2
Get “https://npm.taobao.org/mirrors/node/latest/SHASUMS256.txt“: tls: failed to verify certificate:
Get “https://npm.taobao.org/mirrors/node/latest/SHASUMS256.txt“: tls: failed to verify certificate:
|
6月前
【Error】fatal: unable to access ‘https://github.com/PanJiaChen/vue-element-admin/‘: OpenSSL SSL_read:
【Error】fatal: unable to access ‘https://github.com/PanJiaChen/vue-element-admin/‘: OpenSSL SSL_read:
成功解决urllib.error.URLError: <urlopen error [Errno 11001] getaddrinfo failed>
成功解决urllib.error.URLError: <urlopen error [Errno 11001] getaddrinfo failed>
|
PyTorch 网络安全 算法框架/工具
下载Pytorch的自带数据集时报错=urllib.error.URLError: urlopen error [SSL: CERTIFICATE_VERIFY_FAILED]
这是一个SSL证书验证错误,当请求一个https站点,但是证书验证错误时,就会报这样的错误。
278 0
|
网络安全
ssl.SSLError [SSL CERTIFICATE_VERIFY_FAILED] certificate verify failed
ssl.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed
230 0
|
Shell 网络安全 开发工具
fatal: unable to access github.com schannel failed to receive handshake, SSL/TLS connection failed
fatal: unable to access github.com schannel failed to receive handshake, SSL/TLS connection failed
283 0
fatal: unable to access 'https://github.com/XXXX.git/': OpenSSL SSL_connect: SSL_ERROR_SYSCALL in connection to github.com:443
fatal: unable to access 'https://github.com/XXXX.git/': OpenSSL SSL_connect: SSL_ERROR_SYSCALL in connection to github.com:443
326 0
|
TensorFlow 网络安全 算法框架/工具
[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate
最近在学习TensorFlow,获取fashion_mnist数据集的时候出现了一点小问题,报错内容如下: URL fetch failure on https://storage.googleapis.com/tensorflow/tf-keras-datasets/train-labels-idx1-ubyte.gz: None -- [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1108) ————————————————
1204 0
[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate
|
网络安全 Python
urllib.error.URLError: urlopen error [SSL: CERTIFICATE_VERIFY_FAILED]
urllib.error.URLError: urlopen error [SSL: CERTIFICATE_VERIFY_FAILED]
359 0