[Yum-devel] urlgrabber socket timeouts

Ryan Tomayko rtomayko at naeblis.cx
Wed Sep 29 14:29:21 UTC 2004


We'll leave it as an option for the future then. Should be easy to 
plug-in if the need arises.

Ryan

On Sep 29, 2004, at 9:55 AM, seth vidal wrote:
> On Wed, 2004-09-29 at 09:51, Ryan Tomayko wrote:
>> If we wanted to get crufty and support < 2.2 we could do something 
>> like:
>>
>> import socket
>> if hasattr(socket, 'setdefaulttimeout'):
>>    set_timeout = socket.setdefaulttimeout
>> else:
>>    try:
>>      import timeoutsocket
>>      set_timeout = timeoutsocket.setDefaultSocketTimeout
>>    except ImportError:
>>      # no possible way of supporting timeout
>>      set_timeout = None
>>
>> Now we can call set_timeout to support both Python 2.3's native 
>> support
>> or, failing that, the timeoutsocket hack for < 2.3.
>>
>> http://www.steffensiebert.de/soft/python/timeoutsocket.py
>>
>> Not sure all this is worth it but I thought I'd throw it out there.
>
> Yah, I'm not sure it's worth it either for that part.
>
> 2.2 systems will slowly dwindle, I think. Still a lot of rhel3 systems
> out there on 2.2, though.
>
> -sv
>
>
> _______________________________________________
> Yum-devel mailing list
> Yum-devel at lists.linux.duke.edu
> https://lists.dulug.duke.edu/mailman/listinfo/yum-devel




More information about the Yum-devel mailing list