commit | fea73efc9ea2a65d73a55f8bab1adfbbca62e38b | [log] [tgz] |
---|---|---|
author | Brett Cannon <brett@python.org> | Fri Apr 27 15:45:15 2012 -0400 |
committer | Brett Cannon <brett@python.org> | Fri Apr 27 15:45:15 2012 -0400 |
tree | 1cffa2268fcd2da4a7e83d76a846bcba79f5980f | |
parent | 6d3b3218be62b723d8aaea1676e8eb7d7b937649 [diff] [blame] |
Issue #14605: Don't error out if get_importer() returns None.
diff --git a/Lib/pkgutil.py b/Lib/pkgutil.py index 932abbc..8e062a4 100644 --- a/Lib/pkgutil.py +++ b/Lib/pkgutil.py
@@ -466,6 +466,8 @@ platform-specific special import locations such as the Windows registry. """ for importer in iter_importers(fullname): + if importer is None: + continue loader = importer.find_module(fullname) if loader is not None: return loader