diff options
author | Claudiu Popa <pcmanticore@gmail.com> | 2016-05-08 16:30:02 +0300 |
---|---|---|
committer | Claudiu Popa <pcmanticore@gmail.com> | 2016-05-08 16:30:02 +0300 |
commit | 50fa4b80dc526eedaf5c878c32c89ad5e054b59e (patch) | |
tree | 2e730a76ba4c42106ea447bba0bdd9019e220bf4 /astroid/modutils.py | |
parent | 969217ee6a0b458941e9477cd69ef32a4b4c54a4 (diff) | |
download | astroid-git-50fa4b80dc526eedaf5c878c32c89ad5e054b59e.tar.gz |
Don't introduce empty values for non-zip importers in path_importer_cache and add a test for implicit namespace packages.
Diffstat (limited to 'astroid/modutils.py')
-rw-r--r-- | astroid/modutils.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/astroid/modutils.py b/astroid/modutils.py index 57c625dc..95a17d45 100644 --- a/astroid/modutils.py +++ b/astroid/modutils.py @@ -653,7 +653,7 @@ def _precache_zipimporters(path=None): try: pic[entry_path] = zipimport.zipimporter(entry_path) except zipimport.ZipImportError: - pic[entry_path] = None + continue return pic @@ -807,7 +807,7 @@ def _find_spec(modpath, path=None): # Need a copy for not mutating the argument. modpath = modpath[:] - submodule_path = [] + submodule_path = None module_parts = modpath[:] processed = [] |