运行python,发送get请求,请求后出现requests.exceptions.SSLError: (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1129)')))
解决办法:
import urllib3
导包后,将urllib3.disable_warnings()写在首部
# encoding:utf-8
import requests
import urllib3
import time
urllib3.disable_warnings()
添加参数 verify=False 到请求中文章来源:https://www.toymoban.com/news/detail-518986.html
response = requests.request(method='GET',
url='https://www.csv.com.cn/api/dc-app-order/open/up/code?signMode=1&clientId=af901bbe65jgebc3d0987a8d289&signTimestamp=123234455656&signData=hdfdgfgdgdfgfhgfh',
params={"outer_number":"662423253430992110","shopId":"A06J"},
verify=False,
json={"userCode": "13800000002", "password": "765496", "tag": "csv",
"locale": "CN"}, headers={"Content-Type": "text/plain"})
r = response.json()
再次运行,正常啦。遇到后解决的小问题,希望对你有帮助。文章来源地址https://www.toymoban.com/news/detail-518986.html
到了这里,关于GET请求带参数,请求后出现Caused by SSLError(SSLCertVerificationError(1, ‘[SSL: CERTIFICATE_VERIFY_FAILED] [已解决]的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!