Issue1218

classification
Title: Socket timeouts on connect not honoured when timeout set through socket.setdefaulttimeout()
Type: behaviour Severity: normal
Components: Library Versions: 2.2.2
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: amak Nosy List: amak
Priority: Keywords:

Created on 2009-01-05.19:32:01 by amak, last changed 2009-01-05.20:00:01 by amak.

Messages
msg4000 (view) Author: Alan Kennedy (amak) Date: 2009-01-05.19:32:01
Socket timeouts are not honoured when the timeouts is set through
socket.setdefaulttimeout.

This code illustrates

######
import socket
import urllib2

socket.setdefaulttimeout(1.0)
print "Connecting ..."
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
s.connect( ("192.168.192.168", 80) )
print "Never reached"
######

This means that modules and functions which use sockets, such as
urllib.urlopen, will fail to correctly timeout.
msg4001 (view) Author: Alan Kennedy (amak) Date: 2009-01-05.20:00:01
Fixed in trunk at r5854  
Fixed in release_22_maint at r5855
History
Date User Action Args
2009-01-05 20:00:01amaksetstatus: open -> closed
resolution: fixed
messages: + msg4001
2009-01-05 19:38:38amaksettitle: Socket connects not honoured when timeout set through socket.setdefaulttimeout() -> Socket timeouts on connect not honoured when timeout set through socket.setdefaulttimeout()
2009-01-05 19:32:01amakcreate