[issue36026] Different error message when sys.settrace is used (regressions)

SylvainDe report at bugs.python.org
Mon Feb 18 18:32:02 EST 2019


SylvainDe <sylvain.desodt at gmail.com> added the comment:

This is mostly true and I agree that error messages are not part of the API.

However, I'd like to add the following points:
 - the error message was more meaningful before
 - the fact that having system.settrace used or not changes the behaviour makes me think this is not intentional.
 - the fact that the behaviour for unit test.assertRaisesRegexp is different depending on whether it is used as a context manager makes me think this is not intentional. From the documentation it seems like the 2 should behave the same way.

Thus, even if this eventually deserves to be closed as a non-issue, I'd rather go on the safe side and double check if this is the desirable behaviour or if something went wrong with the commits previously mentioned. Maybe Jeroen Demeyer (jdemeyer) would have more hindsight about this.

Does that look like an acceptable trade off?

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue36026>
_______________________________________


More information about the Python-bugs-list mailing list