summaryrefslogtreecommitdiff
path: root/astroid/helpers.py
diff options
context:
space:
mode:
authorClaudiu Popa <pcmanticore@gmail.com>2018-03-05 11:30:44 +0100
committerClaudiu Popa <pcmanticore@gmail.com>2018-03-05 11:30:44 +0100
commit2c1e49542a800875904e36e6ac9309c96f7f989c (patch)
tree30d191843a4a112bc4b869bfbb944e539e7c1b65 /astroid/helpers.py
parentceb81955278f98447153efc6fae4224b2dfb71db (diff)
downloadastroid-git-2c1e49542a800875904e36e6ac9309c96f7f989c.tar.gz
Make sure to handle Uninferable by returning it rather than returning an exception
Diffstat (limited to 'astroid/helpers.py')
-rw-r--r--astroid/helpers.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/astroid/helpers.py b/astroid/helpers.py
index 8ea6c4da..2e633a07 100644
--- a/astroid/helpers.py
+++ b/astroid/helpers.py
@@ -100,8 +100,8 @@ def object_isinstance(node, class_or_seq, context=None):
class_seq = class_or_seq
obj_type = object_type(node, context)
if obj_type is util.Uninferable:
- return exceptions.InferenceError(
- "{node} cannot be inferred".format(node=node))
+ return util.Uninferable
+
# Instances are not types
class_seq = [item if not isinstance(item, bases.Instance)
else util.Uninferable for item in class_seq]