[New-bugs-announce] [issue36282] Not accurate error message for exact number of positional arguments
Serhiy Storchaka
report at bugs.python.org
Wed Mar 13 16:44:52 EDT 2019
New submission from Serhiy Storchaka <storchaka+cpython at gmail.com>:
Due to minor error, the error message for too many positional arguments is not accurate if the function uses Argument Clinic.
For example:
>>> int.from_bytes(b'a', 'little', False)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: from_bytes() takes at most 2 positional arguments (3 given)
This is correct, but not accurate, because from_bytes() takes *exactly* 2 positional arguments.
----------
components: Interpreter Core
messages: 337874
nosy: serhiy.storchaka
priority: normal
severity: normal
status: open
title: Not accurate error message for exact number of positional arguments
type: behavior
versions: Python 3.8
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue36282>
_______________________________________
More information about the New-bugs-announce
mailing list