Julien Palard added the comment: OK, so, requests have a `timeout` and take it into account, and it solves my problem.
Yet I don't understand one little thing: With both requests `timeout` parameter set or unset, the exact same http.client.py:_read_status call the same socket.readinto. With a `request` `timeout`, the socket.readinto uses the recvfrom syscall, but with a `request` `timeout`, readinto uses a `poll` syscall with the given timeout. The root of the problem is that urllib3 ignores the `socket` `defaulttimeout`, I opened a ticket on this: https://github.com/shazow/urllib3/issues/655#issuecomment-114835279 So this ticket can be considered closed. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue24486> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com