R. David Murray added the comment:
Yes, it looks to me like urllib is intentionally putting the 'socket
error' or 'url error' into the errno position in the IOError arguments.
Now that socket.error is an IOError, that at least seems wrong.
--
nosy: +r.david.murray
Amaury Forgeot d'Arc added the comment:
No, it seems that 2.5 has the same problem. The 'socket error' message is
raised in urllib.py. The socket module is innocent to me...
It appears that this file routinely raises IOErrors, passing various
arguments, which are not stored properly in the IO
New submission from Ezio Melotti :
In Python 2.6, socket.error was changed to be a child class of IOError
[1]. IOError derives from EnvironmentError [2], and EnvironmentError
accepts a 2-tuple used to set the values of the errno and strerror
attributes respectively [3].
Apparently the IOError rai