Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix walk_trace_chain: change container for seen_exceptions #411

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions rollbar/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -791,7 +791,7 @@ def _report_exc_info(exc_info, request, extra_data, payload_data, level=None):
def _walk_trace_chain(cls, exc, trace):
trace_chain = [_trace_data(cls, exc, trace)]

seen_exceptions = {exc}
seen_exceptions = [exc]

while True:
exc = getattr(exc, '__cause__', None) or getattr(exc, '__context__', None)
Expand All @@ -800,7 +800,7 @@ def _walk_trace_chain(cls, exc, trace):
trace_chain.append(_trace_data(type(exc), exc, getattr(exc, '__traceback__', None)))
if exc in seen_exceptions:
break
seen_exceptions.add(exc)
seen_exceptions.append(exc)

return trace_chain

Expand Down