New submission from Serhiy Storchaka <storchaka+cpyt...@gmail.com>:

C API functions like PyDict_GetItem() and PyObject_HasAttr() suppresses all 
errors that may occur, including MemoryError and KeyboardInterrupt. They can 
return incorrect result when the memory is exhausted or the user presses 
Ctrl-C. The proposed PR documents such functions and suggests the C API which 
do not swallow unrelated exceptions.

Previous attempt to document this (for PyDict_GetItem() only) was in issue20615.

----------
assignee: docs@python
components: Documentation
messages: 331620
nosy: docs@python, rhettinger, ronaldoussoren, serhiy.storchaka, vstinner
priority: normal
severity: normal
status: open
title: Document C API functions which swallow exceptions
type: enhancement
versions: Python 2.7, Python 3.6, Python 3.7, Python 3.8

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

Reply via email to