Make is_package a function and call it consistently
This commit is contained in:
1 parent
6ffeea7eea
commit
8a26a23884
7 files changed
+19
-10
No files matched your search
@@ -235,7 +235,7 @@ def _load_from_typeshed(inference_state, python_value_set, parent_module_value,
|
||||
map_ = _cache_stub_file_map(inference_state.grammar.version_info)
|
||||
import_name = _IMPORT_MAP.get(import_name, import_name)
|
||||
elif isinstance(parent_module_value, ModuleValue):
|
||||
if not parent_module_value.is_package:
|
||||
if not parent_module_value.is_package():
|
||||
# Only if it's a package (= a folder) something can be
|
||||
# imported.
|
||||
return None
|
||||
|
||||
Reference in new issue
Block a user