Home
Sign Up
Sign In
推荐学习书目
›
Learn Python the Hard Way
Python Sites
›
PyPI
- Python Package Index
›
http://diveintopython.org/toc/index.html
›
Pocoo
值得关注的项目
›
PyPy
›
Celery
›
Jinja2
›
Read the Docs
›
gevent
›
pyenv
›
virtualenv
›
Stackless Python
›
Beautiful Soup
›
结巴中文分词
›
Green Unicorn
›
Sentry
›
Shovel
›
Pyflakes
›
pytest
Python 编程
›
pep8 Checker
Styles
›
PEP 8
›
Google Python Style Guide
›
Code Style from The Hitchhiker's Guide
V2EX
›
Python
求教,gevent + urllib2 采集https://code.google.com抛出一堆错误 _ssl.c:504: EOF occurred in violation of protocol
ioven
·
May 22, 2013
· 5952 views
This topic created in 4790 days ago, the information mentioned may be changed or developed.
urllib2
gevent
求教
7 replies
•
1970-01-01 08:00:00 +08:00
1
ljbha007
May 22, 2013
多半是被墙了
2
ioven
OP
May 22, 2013
@
ljbha007
木被墙,单用urllib2完全木问题
3
feisuzhu
May 23, 2013
monkey_patch的时候有没有指定patch_ssl?
4
ioven
OP
May 24, 2013
@
feisuzhu
__import__('gevent.monkey').monkey.patch_all(thread=False)
5
feisuzhu
May 24, 2013
@
ioven
抱歉我也没有过patch_ssl。monkey_patch尽量放到所有import的前面。还有就是,你可以试试gevent1.0,尽管还是beta,但是beta了好久了。
6
ioven
OP
May 24, 2013
@
feisuzhu
gevent 1.0 官网,pypi找了一圈也没找到,求下载地址
7
ioven
OP
May 25, 2013
找到原因了,采集的数据保存用的是mysql,MySQLdb无法被gevent path,所以线程阻塞导致urllib2出现错误
偶是白痴。。。
About
·
Help
·
Advertise
·
Blog
·
API
·
FAQ
·
Solana
·
2802 Online
Highest 6679
·
Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 43ms ·
UTC 11:33
·
PVG 19:33
·
LAX 04:33
·
JFK 07:33
♥ Do have faith in what you're doing.
❯