解决python爬虫requests.exceptions.SSLError: HTTPSConnectionPool(host='XXX', port=443)问题
爬虫时报错如下:
requests.exceptions.SSLError: HTTPSConnectionPool(host='某某某网站', port=443):
Max retries exceeded with url: /login/ (Caused by SSLError(SSLError("bad handshake:
Error([('SSL routines', 'tls_process_server_certificate', 'certificate verify failed
1.先检查pip有没安装cryptography,pyOpenSSL,certifi要是没有先安装
pip install cryptography
pip install pyOpenSSL
pip install certifi
(我是将上面的第三方包安装好后就不再报错了)
2.要是以上这些已安装还是继续报错,则在网页请求代码中加上这个 verify=False 就可以解决报错,代码可运行。
————————————————
原文链接:https://blog.csdn.net/weixin_44385104/article/details/94750593
解决python爬虫requests.exceptions.SSLError: HTTPSConnectionPool(host='XXX', port=443)问题的更多相关文章
- 关于python3.6上传文件时报错:HTTPSConnectionPool(host='***.org', port=443): Max retries exceeded with url: /post (Caused by SSLError(SSLError(1, '[SSL: CERTIFICATE_VERIFY_FAIL解决办法
第一个报错: 最近在练习post请求中上传文件时遇到了一个奇葩事情,两台电脑上写了一模一样的代码,一个运行正常,另一个一片红. 最后了解了一下原因以及解决办法.先记录下关键代码: files = {& ...
- python使用requests时报错requests.exceptions.SSLError: HTTPSConnectionPool
报错信息 Traceback (most recent call last): File "<stdin>", line 1, in <module> Fi ...
- 关于requests.exceptions.SSLError: HTTPSConnectionPool
问题: requests.exceptions.SSLError: HTTPSConnectionPool(host='mall.christine.com.cn', port=443): Max r ...
- 解决pip._vendor.urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='files.pythonhosted.org', port=443): Read timed out.
参考链接[侵权删] https://www.jianshu.com/p/3378fa827924 https://yq.aliyun.com/articles/619208 问题描述:在Windows ...
- HTTPSConnectionPool(host='xxxxx', port=443): Max retries exceeded with url:xxxxxxxx (Caused by NewConnectionError('<urllib3.connect,Max retries exceeded with ,(Caused by NewConnectionError
HTTPSConnectionPool(host='f6ws-sha8re-o88k.s3.ama66zaws.com', port=443): Max retries exceeded with u ...
- 安装SpaCy出现报错:requests.exceptions.ConnectionError: HTTPSConnectionPool(host='raw.githubusercontent.com', port=443):
内含安装步骤及报错解决:https://www.cnblogs.com/xiaolan-Lin/p/13286885.html
- 解决pip._vendor.urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='files.pythonhosted.org', port=443): Read timed out.问题
国内的其他镜像源清华大学 https://pypi.tuna.tsinghua.edu.cn/simple/阿里云 http://mirrors.aliyun.com/pypi/simple/中国科技 ...
- Python中request的post请求报requests.exceptions.SSLError:
今天发送一个post请求,提示错误 requests.exceptions.SSLError: HTTPSConnectionPool(host='user.zaful.com', port=443) ...
- requests.exceptions.SSLError……Max retries exceeded with url错误求助!!!
import requests head = {"User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) Appl ...
随机推荐
- VUE框架思想
学习VUE的第一步就是先了解这个框架的的核心思想 Vue.js的核心思想就是,它是一套__渐进式的自底层向上增量开发__的__MVVM__结构的框架 什么是框架? 简单的讲,框架就是将与业务无关的重复 ...
- 【53.57%】【codeforces 610C】Harmony Analysis
time limit per test3 seconds memory limit per test256 megabytes inputstandard input outputstandard o ...
- iptables总结,开启端口,查看端口占用情况
Centos查看端口占用情况和开启端口命令 Centos查看端口占用情况命令,比如查看80端口占用情况使用如下命令: lsof -i tcp:80 列出所有端口 netstat -ntlp mac上查 ...
- 十二、格式化I/O
1.fprintf 表头文件 #include<stdio.h> 定义函数 int fprintf(FILE * stream, const char * format,.......); ...
- slim中的请求URI
请求 URI 每个 HTTP 请求都有一个识别被请求的应用程序资源的 URI .HTTP 请求 URI 分为这几部分: Scheme (e.g. http or https) Host (e.g. e ...
- MySQL基础篇(03):系统和自定义函数总结,触发器使用详解
本文源码:GitHub·点这里 || GitEE·点这里 一.系统封装函数 MySQL 有很多内置的函数,可以快速解决开发中的一些业务需求,大概包括流程控制函数,数值型函数.字符串型函数.日期时间函数 ...
- python 连接 SQL Server 数据库
#!/usr/bin/python # -*- coding:utf-8 -*- import pymssql import pyodbc host = '127.0.0.1:1433' user = ...
- 使用eclipse创建第一个SpringBoot项目
1.new->maven->maven project, 勾选 Create a simple project, 下一个页面中填入group id(项目组织唯一标识, 如org.ap ...
- 在Asp.Net Core中使用ModelConvention实现全局过滤器隔离
从何说起 这来自于我把项目迁移到Asp.Net Core的过程中碰到一个问题.在一个web程序中同时包含了MVC和WebAPI,现在需要给WebAPI部分单独添加一个接口验证过滤器IActionFil ...
- Mysql 字段类型与约束条件
一.数值类型 二.日期类型 三.枚举与集合 四.约束条件 五.设置严格模式 一.数值类型 1.1 整型 应用场景: id号.年龄... tinyint: 有符号:默认范围 -128, 127 无符号: ...