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
{{ message }}
Repository navigation
Fix support of var-positional parameter in Argument Clinic #122688
Currently Argument Clinic with a var-positional parameter is only used in few functions (print(), the TypeVar constructor (see #118814) and several set methods), so this is not well tested.
There are several bugs here:
Keyword-only parameters after the var-positional parameter are marked as positional-or-keyword parameters.
The number of required arguments for keyword-only parameters was calculated incorrectly.
Some invalid combination of the var-positional parameter with /, * and deprecation markers are not forbidden or produce unrelated errors.
Due to refactoring it is difficult to backport this change to 3.12. This is not such important, because these corner cases are not used in CPython for now.
But I am planning to merge it in 3.13 after release, to help backporting future bugfixes. I am currently working on significant rewriting of the code for this feature, and found few other errors.
Activity
pythongh-122688: Fix support of var-positional parameter in Argument …
gh-122688: Fix support of var-positional parameter in Argument Clinic (…
[3.13] pythongh-122688: Fix support of var-positional parameter in Ar…
serhiy-storchaka commentedon Aug 9, 2024
Due to refactoring it is difficult to backport this change to 3.12. This is not such important, because these corner cases are not used in CPython for now.
But I am planning to merge it in 3.13 after release, to help backporting future bugfixes. I am currently working on significant rewriting of the code for this feature, and found few other errors.
pythongh-122688: Add more tests for var-positional parameters in Argu…
gh-122688: Add more tests for var-positional parameters in Argument C…
pythongh-122688: Fix support of var-positional parameter in Argument …
pythongh-122688: Add more tests for var-positional parameters in Argu…
[3.13] gh-122688: Fix support of var-positional parameter in Argument…