Terry J. Reedy added the comment: This issue is spun-off from #29162, which was about idlelib.pyshell depending on import * importing sys.
'wantobjects' does not have the same bug potential as stdlib imports. But, Serhiy, if you care about it or otherwise prefer __all__, __all__ = [name for name in globals() if not name.startswith('_') and name not in {'enum', 're', 'sys', 'wantobjects'}] should work if placed near the end of the file, just before 'def _test'. Except for the exclusion set, I presume that 'import *' does essentially the same iteration ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue29446> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com