python 使用requests 请求 https 接口 ,取消警告waring

时间:2023-03-09 03:05:33
python 使用requests 请求 https 接口 ,取消警告waring
response = requests.request("POST", url, timeout=20, data=payload, headers=headers, proxies=real_proxy,
verify=False)

使用  verify=False   后 出现 waring  警告

在 代码 的 最上方 加上

# 禁用安全请求警告
requests.packages.urllib3.disable_warnings(InsecureRequestWarning)