New submission from Ezio Melotti: This came up in #16515. While using PyArg_UnpackTuple to parse the positional arguments in a function that receives both positional and keyword arguments, the error message returned when the number of arguments is incorrect is misleading, e.g.: >>> max(foo=1) TypeError: max expected 1 arguments, got 0
This can be fixed by adding "positional" before "arguments" in the error message. The attached patch fixes this and the pluralization of "argument(s)". ---------- assignee: ezio.melotti components: Interpreter Core files: unpacktuple.diff keywords: patch messages: 176202 nosy: ezio.melotti priority: normal severity: normal stage: test needed status: open title: Use "positional arguments" in PyArg_UnpackTuple type: enhancement versions: Python 2.7, Python 3.2, Python 3.3, Python 3.4 Added file: http://bugs.python.org/file28090/unpacktuple.diff _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue16543> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com