We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 98483e5 commit b89fa4cCopy full SHA for b89fa4c
src/controller/python/chip/exceptions/__init__.py
@@ -35,7 +35,19 @@
35
36
37
class ChipStackException(Exception):
38
- pass
+ def __reduce__(self):
39
+ """
40
+ Allows this exception to be pickled by returning a simplified Exception
41
+ with the same message, ensuring it can be safely transferred across
42
+ processes in multiprocessing environments.
43
+
44
+ Note:
45
+ This replaces the custom exception with a plain Exception during
46
+ pickling, preserving the message but not the exception type, to avoid
47
+ import errors in environments where this exception class is unavailable.
48
49
50
+ return (Exception, (str(self),))
51
52
53
class ChipStackError(ChipStackException):
0 commit comments