This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author vaultah
Recipients Arfrever, brett.cannon, eric.snow, ezio.melotti, mattheww, ncoghlan, vaultah
Date 2017-08-22.16:43:55
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
In order to load and compile the module code, runpy calls the loader's get_code method. Because that happens outside of the normal import process, and PyImport_ImportModuleLevelObject is currently the only place where remove_importlib_frames is being invoked, tracebacks of exceptions occurring in get_code are kept unmodified.

Would it be wrong to drop all importlib frames from all unhandled exceptions, except when the -v flag is present? On the other hand, since the patch from #issue15486 seems to work fine in most scenarios, I propose removing both runpy and importlib traceback entries locally inside the runpy module. There may be better solutions, though...

In any case, I'm willing to write a patch.
Date User Action Args
2017-08-22 16:43:56vaultahsetrecipients: + vaultah, brett.cannon, ncoghlan, mattheww, ezio.melotti, Arfrever, eric.snow
2017-08-22 16:43:56vaultahsetmessageid: <>
2017-08-22 16:43:56vaultahlinkissue16217 messages
2017-08-22 16:43:55vaultahcreate