forked from VimPlug/jedi
Dynamic array checking in combination with FakeSequences might have caused an exception.
This commit is contained in:
@@ -425,7 +425,13 @@ def check_array_additions(evaluator, array):
|
|||||||
return []
|
return []
|
||||||
|
|
||||||
is_list = array.type == 'list'
|
is_list = array.type == 'list'
|
||||||
current_module = array.atom.get_parent_until()
|
try:
|
||||||
|
current_module = array.atom.get_parent_until()
|
||||||
|
except AttributeError:
|
||||||
|
# If there's no get_parent_until, it's a FakeSequence or another Fake
|
||||||
|
# type. Those fake types are used inside Jedi's engine. No values may
|
||||||
|
# be added to those after their creation.
|
||||||
|
return []
|
||||||
return _check_array_additions(evaluator, array, current_module, is_list)
|
return _check_array_additions(evaluator, array, current_module, is_list)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user