Martin Panter added the comment:

Good point Serhiy about returning subclasses. I’ll see about making that more 
explicit if I can’t find it already documented somewhere.

Regarding the number of arguments, I resisted documenting what happens to extra 
arguments since the behaviour has changed over time, and it doesn’t seem that 
it would be very useful. IMO it would be better to say passing extra arguments 
is not supported. But if others disagree, I can have a go at documenting the 
existing and/or past behaviour.

Python 3.3.3 under Wine:
>>> OSError(None, "Not found", "file", 3).args 
(2, 'Not found', 'file', 3)
>>> OSError(ENOENT, "Not found", "file", None).args
(2, 'Not found', 'file', None)

Python 3.6.0a0 under Linux:
>>> OSError(ENOENT, "Not found", "file", None).args
(2, 'Not found')

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue23391>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to