New submission from Don Caldwell <dfw...@gmail.com>: in iter_modules there is a loop for fn in os.listdir(path): that can fail on an OSError exception. here is a patch
try: for fn in os.listdir(path): subname = inspect.getmodulename(fn) if subname=='__init__': ispkg = True break else: continue # not a package except OSError as (errno, strerror): print "%s: %s\n" % (fn, strerror) ---------- components: Library (Lib) messages: 153421 nosy: dfwc priority: normal severity: normal status: open title: bug in pkgutil.py with suggested fix versions: Python 2.6 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue14022> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com