New submission from Serhiy Storchaka <storchaka+cpyt...@gmail.com>:
Example: >>> from typing import NamedTuple >>> import pickle >>> class A: ... class B(NamedTuple): ... x: int ... >>> pickle.dumps(A.B) Traceback (most recent call last): File "<stdin>", line 1, in <module> _pickle.PicklingError: Can't pickle <class '__main__.B'>: attribute lookup B on __main__ failed ---------- components: Library (Lib) messages: 354176 nosy: gvanrossum, levkivskyi, serhiy.storchaka priority: normal severity: normal status: open title: Nested subclasses of typing.NamedTuple are not pickleable type: behavior versions: Python 3.7, Python 3.8, Python 3.9 _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue38405> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com