-
-
Notifications
You must be signed in to change notification settings - Fork 32k
gh-104860: Fix allow_abbrev=False for single-dash long options #124340
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
gh-104860: Fix allow_abbrev=False for single-dash long options #124340
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The change LGTM but I didn't approve the PR since I don't know well argparse code base. The test covers the changed code.
I'm not sure if we should backport the change since it changes the behavior which is there since Python 3.8. Even if it's a bug, users may rely on the current behavior.
I think this is pretty safe change. It makes the code working as it is supposed to work, as it is documented, and as it worked it the past. If you do not want to disallow abbreviation, just do not use |
Thanks @serhiy-storchaka for the PR 🌮🎉.. I'm working now to backport this PR to: 3.12, 3.13. |
…ythonGH-124340) (cherry picked from commit 49e105f) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
GH-124749 is a backport of this pull request to the 3.13 branch. |
…ythonGH-124340) (cherry picked from commit 49e105f) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
GH-124750 is a backport of this pull request to the 3.12 branch. |
…GH-124340) (GH-124750) (cherry picked from commit 49e105f) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
…GH-124340) (GH-124749) (cherry picked from commit 49e105f) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Uh oh!
There was an error while loading. Please reload this page.