You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While playing around with the main CPython branch against I noticed that enumerate now gives a strange error message when iterable is provided as a keyword argument:
>>> enumerate(iterable=[])
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: enumerate() missing required argument 'iterable'
When passing an invalid keyword argument (and no positional arguments) an interesting error message is also given:
>>> enumerate(hello="world")
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: enumerate() missing required argument 'iterable'
The help output still shows that iterable is accepted as either a keyword argument or a positional argument.
I can confirm that the behavior changed between 3.10 and current main: enumerate(iterable=[]) works on 3.10 but not on main. It's likely a consequence of bpo-43706.
I'll submit a patch to restore the previous behavior.
So since no more regression is expected, I would like to propose merging the PR and once we need to change the implementation, we can revert Vectorcall anytime, Rollbacking Vectorcall will not raise any behavior regression so anytime we can rollback it.
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: