[New-bugs-announce] [issue26312] Raise SystemError on programmical errors in PyArg_Parse*()

Serhiy Storchaka report at bugs.python.org
Mon Feb 8 14:39:33 EST 2016


New submission from Serhiy Storchaka:

For now programmical errors with the use of PyArg_ParseTuple() cause raising SystemError. But some programmical errors with the use of PyArg_ParseTupleAndKeywords() cause raising RuntimeError. I think that SystemError is the correct exception type.

Proposed patch replaces RuntimeError with SystemError in PyArg_ParseTupleAndKeywords(). This change shouldn't break any code (except CPython tests for PyArg_ParseTupleAndKeywords()), because this exception never raised if PyArg_Parse*() functions are used correctly.

----------
components: Interpreter Core
files: pyarg_parse_error.patch
keywords: patch
messages: 259877
nosy: serhiy.storchaka
priority: normal
severity: normal
stage: patch review
status: open
title: Raise SystemError on programmical errors in PyArg_Parse*()
type: enhancement
versions: Python 3.6
Added file: http://bugs.python.org/file41859/pyarg_parse_error.patch

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue26312>
_______________________________________


More information about the New-bugs-announce mailing list