Serhiy Storchaka added the comment:
The details can be different. For example:
>>> 1 .__add__(x=2)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: wrapper __add__ doesn't take keyword arguments
The message contains the word "wrapper" and doesn't contains parenthesis. I
think it can be extended for containing the type name ("int.__add__()" or
"wrapper __add__ of in objects"), and this hard to do with general
_PyErr_NoKeywords(). Let first unify messages, then try to add more useful
information in messages and create a general API if this is possible.
----------
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue30534>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com