summaryrefslogtreecommitdiffstats
path: root/Lib/traceback.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/traceback.py')
-rw-r--r--Lib/traceback.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/Lib/traceback.py b/Lib/traceback.py
index ab35da9..7a4c8e1 100644
--- a/Lib/traceback.py
+++ b/Lib/traceback.py
@@ -538,7 +538,9 @@ class TracebackException:
self.__cause__._load_lines()
def __eq__(self, other):
- return self.__dict__ == other.__dict__
+ if isinstance(other, TracebackException):
+ return self.__dict__ == other.__dict__
+ return NotImplemented
def __str__(self):
return self._str