Message286788
I like the idea since I just proposed something similar in the issue #29419, but it seems like your change removes the function name from error messages which can become much more obscure.
Maybe we should wrap all exceptions into a new TypeError which contains at least the function name, or even the parameter name/position. I mean chained exception to keep the original exception which contains more information.
The best would be to have all information in a single error message, but it is likely to be much more complex to implement, especially if you want to support arbitrary converter function, not only simple formats like i". So I think that two chained exceptions is a reasonable compromise. What do you think?
If we succeed to get the function name and the parameter name or position, the error messages will be MUCH MORE better than currently! And Argument Clinic allows us to implement this feature. |
|
Date |
User |
Action |
Args |
2017-02-02 13:50:39 | vstinner | set | recipients:
+ vstinner, larry, serhiy.storchaka |
2017-02-02 13:50:39 | vstinner | set | messageid: <1486043439.87.0.382370321852.issue23867@psf.upfronthosting.co.za> |
2017-02-02 13:50:39 | vstinner | link | issue23867 messages |
2017-02-02 13:50:39 | vstinner | create | |
|