mirror of
https://github.com/davidhalter/jedi.git
synced 2025-12-06 14:04:26 +08:00
@@ -248,7 +248,7 @@ class ValueNameMixin:
|
||||
|
||||
def get_defining_qualified_value(self):
|
||||
context = self.parent_context
|
||||
if context.is_module() or context.is_class():
|
||||
if context is not None and (context.is_module() or context.is_class()):
|
||||
return self.parent_context.get_value() # Might be None
|
||||
return None
|
||||
|
||||
|
||||
@@ -43,6 +43,9 @@ def test_implicit_namespace_package(Script):
|
||||
solution = "foo = '%s'" % solution
|
||||
assert completion.description == solution
|
||||
|
||||
c, = script_with_path('import pkg').complete()
|
||||
assert c.docstring() == ""
|
||||
|
||||
|
||||
def test_implicit_nested_namespace_package(Script):
|
||||
code = 'from implicit_nested_namespaces.namespace.pkg.module import CONST'
|
||||
|
||||
Reference in New Issue
Block a user