curl-and-python

Re: CURLE_OPERATION_TIMEDOUT while connecting.

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Thu, 3 May 2012 22:35:30 +0200 (CEST)

On Thu, 3 May 2012, Evgeny Turnaev wrote:

> In other words when i call setopt(pycurl.TIMEOUT, 5) a time diff will
> be calculated with now or with some stored value?

TIMEOUT means you allow the request to take no longer than 5 seconds. I'm not
sure what the differences between your options are so I can't really answer.

> The reason i am asking is because it is seems all owrking ok with
> multi.socket_action(pycurl.SOCKET_TIMEOUT, 0) when i do not set timeouts (
> setopt(pycurl.TIMEOUT, 5) and setopt(pycurl.CONNECTTIMEOUT, 1) )

Without timeout set you get no CURLE_OPERATION_TIMEDOUT ? Is that *really* a
surprise?

And you use a 1 second timeout for connections, when only the DNS resolve part
easily can take longer than so for some cases...

-- 
  / daniel.haxx.se
_______________________________________________
http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-python
Received on 2012-05-03