Skip to content

Commit

Permalink
Suppress exception context describing a cache miss
Browse files Browse the repository at this point in the history
Refs pylint-dev/pylint#8716
  • Loading branch information
jacobtylerwalls committed Jun 7, 2023
1 parent bd78ab0 commit 2a643b3
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions astroid/inference_tip.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,9 @@ def inner(
result = _cache[func, node, context] = list(
func(node, context, **kwargs)
)
except Exception as e:
# Suppress the KeyError from the cache miss.
raise e from None
finally:
# Remove recursion guard.
try:
Expand Down

0 comments on commit 2a643b3

Please sign in to comment.