Skip to content

[3.13] gh-64502: Fix Argument Clinic support of optional groups with defaults (GH-155191) - #155217

Open
serhiy-storchaka wants to merge 1 commit into
python:3.13from
serhiy-storchaka:backport-caac9278-3.13
Open

[3.13] gh-64502: Fix Argument Clinic support of optional groups with defaults (GH-155191)#155217
serhiy-storchaka wants to merge 1 commit into
python:3.13from
serhiy-storchaka:backport-caac9278-3.13

Conversation

@serhiy-storchaka

@serhiy-storchaka serhiy-storchaka commented Aug 5, 2026

Copy link
Copy Markdown
Member

Parameters with a default value which are not in any group were always
required in the generated argument parsing code, although they were
rendered as optional in the signature. They can now be omitted, and
ambiguous combinations of optional groups and parameters with a default
value are rejected.
(cherry picked from commit caac927)

Co-authored-by: Serhiy Storchaka storchaka@gmail.com
Co-Authored-By: Claude Opus 5 (1M context) noreply@anthropic.com

…efaults (pythonGH-155191)

Parameters with a default value which are not in any group were always
required in the generated argument parsing code, although they were
rendered as optional in the signature.  They can now be omitted, and
ambiguous combinations of optional groups and parameters with a default
value are rejected.
(cherry picked from commit caac927)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant