1
0
forked from VimPlug/jedi

Differentiate between namespace and module as a type

Also fixed a bug related to implicit namespace contexts, fixes #1033.
This commit is contained in:
Dave Halter
2018-01-25 20:35:54 +01:00
parent 33c9d21e35
commit 04fba28d35
4 changed files with 12 additions and 9 deletions

View File

@@ -419,7 +419,7 @@ class Importer(object):
for context in self.follow():
# Non-modules are not completable.
if context.api_type != 'module': # not a module
if context.api_type not in ('namespace', 'module'): # not a module
continue
# namespace packages
if isinstance(context, ModuleContext) and context.py__file__().endswith('__init__.py'):