Raymond Hettinger <raymond.hettin...@gmail.com> added the comment:
Pickling customized subclasses can be tricky. The essential details are here: https://docs.python.org/3/library/pickle.html#object.__reduce__ Here's some code to get you started. class ExcA(Exception): def __init__(self, want): msg = "missing " msg += want super().__init__(msg) def __reduce__(self): return (type(self), self.args, self.args) def __setstate__(self, state): self.args = stat ---------- nosy: +rhettinger _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue45112> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com