Skip to content

Conversation

davidism
Copy link
Member

closes #1536

The traceback formatter followed exc_value.__context__ infinitely, even if there was a cycle. Add a memo set to track what's been seen already and break when it detects a cycle.

@davidism davidism added this to the 0.15.3 milestone May 12, 2019
@davidism davidism merged commit bdc17e4 into 0.15.x May 12, 2019
@davidism davidism deleted the break-tb-cycle branch May 12, 2019 14:55
memo = set()
while True:
self.groups.append(Group(exc_type, exc_value, tb))
memo.add(exc_value)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this assumes hashability of exceptions (which isn't always true), I wrote a fix for this: #1542

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 13, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants