mirror of
https://github.com/python/cpython.git
synced 2025-08-31 14:07:50 +00:00
bpo-45607: Make it possible to enrich exception displays via setting their __note__ field (GH-29880)
This commit is contained in:
parent
d9301703fb
commit
5bb7ef2768
10 changed files with 183 additions and 5 deletions
|
@ -1298,13 +1298,13 @@ class SizeofTest(unittest.TestCase):
|
|||
class C(object): pass
|
||||
check(C.__dict__, size('P'))
|
||||
# BaseException
|
||||
check(BaseException(), size('5Pb'))
|
||||
check(BaseException(), size('6Pb'))
|
||||
# UnicodeEncodeError
|
||||
check(UnicodeEncodeError("", "", 0, 0, ""), size('5Pb 2P2nP'))
|
||||
check(UnicodeEncodeError("", "", 0, 0, ""), size('6Pb 2P2nP'))
|
||||
# UnicodeDecodeError
|
||||
check(UnicodeDecodeError("", b"", 0, 0, ""), size('5Pb 2P2nP'))
|
||||
check(UnicodeDecodeError("", b"", 0, 0, ""), size('6Pb 2P2nP'))
|
||||
# UnicodeTranslateError
|
||||
check(UnicodeTranslateError("", 0, 1, ""), size('5Pb 2P2nP'))
|
||||
check(UnicodeTranslateError("", 0, 1, ""), size('6Pb 2P2nP'))
|
||||
# ellipses
|
||||
check(Ellipsis, size(''))
|
||||
# EncodingMap
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue