Eric Snow added the comment:

Here's a patch that checks for modules that don't have __spec__ set.

The patch will fix the problem.  However note that the docs and docstring imply 
(to me) that we should turn any ImportError coming out of the find_loader() 
call into returning None.  Fixing that will also fix this bug, so this patch 
may be unnecessary.

----------
keywords: +patch
stage: test needed -> patch review
Added file: http://bugs.python.org/file34808/issue21200-pkgutil-main.diff

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue21200>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to