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 serhiy.storchaka
Recipients barry, serhiy.storchaka
Date 2018-09-20.17:33:39
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1537464819.33.0.956365154283.issue34756@psf.upfronthosting.co.za>
In-reply-to
Content
The proposed PR makes the following changes in sys.breakpointhook():

* Use _PyObject_GetBuiltin() for getting a builtin. This simplifies the code.

* The only effect of using the "from" list is when the imported name is a submodule. But it should be a callable. Callable module is very rare bird, I don't think we need to support such weird case. Removing the "from" list simplifies the code.

* Only ImportError and AttributeError raised from import are ignored. Other errors are exposed to the user as is. This is most likely a KeyboardInterrupt or MemoryError. They shouldn't be silenced.

sys.breakpointhook() was added in issue31353.
History
Date User Action Args
2018-09-20 17:33:39serhiy.storchakasetrecipients: + serhiy.storchaka, barry
2018-09-20 17:33:39serhiy.storchakasetmessageid: <1537464819.33.0.956365154283.issue34756@psf.upfronthosting.co.za>
2018-09-20 17:33:39serhiy.storchakalinkissue34756 messages
2018-09-20 17:33:39serhiy.storchakacreate