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

2019-04-01 Thread Inada Naoki
Change by Inada Naoki : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___ P

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

2019-04-01 Thread Inada Naoki
Inada Naoki added the comment: New changeset 62f9588663ebfea1735e9d142ef527395a6c2b95 by Inada Naoki in branch 'master': bpo-36026: make descr error message consistent (GH-11930) https://github.com/python/cpython/commit/62f9588663ebfea1735e9d142ef527395a6c2b95 -- __

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

2019-02-19 Thread STINNER Victor
Change by STINNER Victor : -- nosy: -vstinner ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.p

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

2019-02-19 Thread INADA Naoki
INADA Naoki added the comment: BTW, should we have different error message for class methods and instance mehtods? * method: "descriptor 'X' for 'Y' objects doesn't apply to a 'Z' object" * classmethod: "descriptor 'X' for 'Y' types doesn't apply to a 'Z' type" Currently, classmethod notice

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

2019-02-19 Thread INADA Naoki
INADA Naoki added the comment: @Serhiy Error messages are not changed in 3.7. They are different from 3.6. Optimization in 3.7 changed "code path", not error message. So it's difficult to fix this without breaking existing behavior. Python 3.6.7 (default, Dec 18 2018, 17:32:18) [GCC 4.2.1 Com

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

2019-02-19 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I consider this as a minor regression in 3.7, unless there were reasons to change error messages. I think that in this case the change that restores error messages should be backported to 3.7. -- ___ Python trac

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

2019-02-19 Thread SylvainDe
SylvainDe added the comment: This looks good to me :) -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: htt

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

2019-02-19 Thread INADA Naoki
INADA Naoki added the comment: Is this make sense? >>> set.add(0) Traceback (most recent call last): File "", line 1, in TypeError: descriptor 'add' for type 'set' doesn't apply to type 'int' >>> set.add.__get__(0) Traceback (most recent call last): File "", line 1, in TypeError: descrip

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

2019-02-19 Thread INADA Naoki
Change by INADA Naoki : -- keywords: +patch pull_requests: +11954 stage: -> patch review ___ Python tracker ___ ___ Python-bugs-lis

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

2019-02-19 Thread SylvainDe
SylvainDe added the comment: Thanks for the investigation. I'm fine with the explanation provided. -- ___ Python tracker ___ ___ Py

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

2019-02-19 Thread INADA Naoki
INADA Naoki added the comment: > 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. As Serhiy mentioned, this error messa

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

2019-02-19 Thread SylvainDe
Change by SylvainDe : -- type: -> behavior versions: +Python 3.7, Python 3.8 ___ Python tracker ___ ___ Python-bugs-list mailing li

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

2019-02-18 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Looks this is due to the method calls optimization (issue26110). We now avoid to create a temporary bound method, and an error with different message is raised on this path. >>> set.add(0) Traceback (most recent call last): File "", line 1, in TypeError

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

2019-02-18 Thread SylvainDe
SylvainDe 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 thi

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

2019-02-18 Thread Steven D'Aprano
Steven D'Aprano added the comment: Do I correctly understand the reported problem here? set.add(0) correctly raises TypeError in each case, but: (1) the exception message changes between versions; (2) and also changes depending on whether or not sys.trace is active. I don't think the except

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

2019-02-18 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +serhiy.storchaka, vstinner ___ Python tracker ___ ___ Python-bugs-list mailing list U

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

2019-02-18 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +xtreak ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https:/

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

2019-02-18 Thread SylvainDe
New submission from SylvainDe : Context: Follow-up from https://bugs.python.org/issue35965 which was closed when we assumed the issue was on the coverage side. After nedbat investigation, it seems like the issue comes from call to "sys.settrace". Issue: -- A test relying on "se