[issue6471] errno and strerror attributes incorrectly set on socket.error

2009-07-12 Thread Ezio Melotti
New submission from Ezio Melotti ezio.melo...@gmail.com: 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].

[issue6471] errno and strerror attributes incorrectly set on socket.error

2009-07-12 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com 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

[issue6471] errno and strerror attributes incorrectly set on socket.error

2009-07-12 Thread R. David Murray
R. David Murray rdmur...@bitdance.com 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