summaryrefslogtreecommitdiff
path: root/astroid/helpers.py
diff options
context:
space:
mode:
Diffstat (limited to 'astroid/helpers.py')
-rw-r--r--astroid/helpers.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/astroid/helpers.py b/astroid/helpers.py
index cb16ecdc..db86606e 100644
--- a/astroid/helpers.py
+++ b/astroid/helpers.py
@@ -150,7 +150,7 @@ def safe_infer(node, context=None):
try:
inferit = node.infer(context=context)
value = next(inferit)
- except exceptions.InferenceError:
+ except (exceptions.InferenceError, StopIteration):
return None
try:
next(inferit)