1
0
forked from VimPlug/jedi

Disable some features for big annoying libraries like pandas, tensorflow, see #520

This commit is contained in:
Dave Halter
2020-01-04 02:39:36 +01:00
parent 441ede2c7f
commit 47d3aa73dc
4 changed files with 17 additions and 2 deletions

View File

@@ -261,3 +261,9 @@ def parse_dotted_names(nodes, is_import_from, until_node=None):
def values_from_qualified_names(inference_state, *names):
return inference_state.import_module(names[:-1]).py__getattribute__(names[-1])
def is_big_annoying_library(context):
string_names = context.get_root_context().string_names
# Pandas is huge, so just ignore it, because stuff makes everything slow.
return string_names[0] in ('pandas', 'numpy', 'tensorflow', 'matplotlib')