Bug report
Bug description:
There is a trailing s at TypeError exception message from initializer of collecitons.OrderedDict.
Test code:
import collections
collections.OrderedDict(1, 2, 3)
And result shows:
Traceback (most recent call last):
File "<python-input-1>", line 2, in <module>
collections.OrderedDict(1, 2, 3)
~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^
TypeError: expected at most 1 arguments, got 3
There is a trailing s at argument.
In other cases, it will show argument if only one argument expected:
import collections
list(1, 2, 3) # TypeError: list expected at most 1 argument, got 3
dict(1, 2, 3) # TypeError: dict expected at most 1 argument, got 3
set(1, 2, 3) # TypeError: set expected at most 1 argument, got 3
collections.OrderedDict(1, 2, 3) # TypeError: expected at most 1 arguments, got 3
CPython versions tested on:
CPython main branch
Operating systems tested on:
Linux
Linked PRs
Bug report
Bug description:
There is a trailing
satTypeErrorexception message from initializer ofcollecitons.OrderedDict.Test code:
And result shows:
There is a trailing
satargument.In other cases, it will show
argumentif only one argument expected:CPython versions tested on:
CPython main branch
Operating systems tested on:
Linux
Linked PRs