Am I misusing socket.setdefaulttimeout here?

Skip Montanaro skip at
Thu Mar 20 19:35:10 CET 2003

    [ traceback when using socket timeouts ]

    Skip>     Traceback (most recent call last):
    Skip>       File "", line 11, in ?
    Skip>         data =
    Skip>       File "/Users/skip/local/lib/python2.3/", line 1155, in read
    Skip>         return s +
    Skip>     IOError: [Errno 35] Resource temporarily unavailable

    Skip> Do I misunderstand something about socket timeouts or do they not
    Skip> play well with urllib and friends (I tried both urllib and
    Skip> urllib2).

Turns out timeouts don't play well with files.  This makes the new socket
timeout capability pretty worthless with higher level modules based on
sockets which use line-oriented protocols (httplib, xmlrpclib, etc) which
always want to deal with files.  Bummer...


More information about the Python-list mailing list