-
Notifications
You must be signed in to change notification settings - Fork 331
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
gevent's monkeypatching breaks timeouts on linux #1
Comments
It seems you are using gevent 0.13.x, you can upgrade to 1.0b2(http://code.google.com/p/gevent/downloads/detail?name=gevent-1.0b2.tar.gz&can=2&q=), or using gevent's Timeout instead of requests' timeout parameter |
I'm seeing similar issues on Mac OSX with libevent installed via brew, gevent 1.0b2 (tried the stable release) and grequests. |
On OSX, and also seeing this issue. The request simply hangs, and never returns. This simply brings the whole script to a halt. Any suggestions? Following code shows hanging behaviour: >>> urls = ['http://www.whatzonip.com/wiki9/index.php?title=Special:UserLogin&type=signup']
>>> rs = (grequests.get(u, timeout=2) for u in urls)
>>> grequests.map(rs) |
all works here on macosx . on linux i tried gevent 0.13.x and 1.0b2 but still get the same error |
You have to use the gevent on github. There has been a patch applied that fixes this, however it's not released in any format yet. Clone the gevent githubo repo and build gevent from there. |
thanks installed from github but JakeAustwick code for example still produces:
pip freeze | grep gevent |
Huh? Isn't that correct? The request is timing out? The problem was that timeouts were not occuring. |
oops my bad. did not use safe_mode=True. but that's another issue with grequests. Thanks |
Please fix this 👍 |
See kennethreitz/requests#500 for context, but basically the timeout is no longer respected after importing the async module that monkeypatches
socket
.The text was updated successfully, but these errors were encountered: