Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork3.1k
Fix argparse for Python 3.14#19020
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
According tomypy_primer, this change doesn't affect type check results on a corpus of open source code. ✅ |
hauntsaninja left a comment
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.
Thanks!
d68ea35 intopython:masterUh oh!
There was an error while loading.Please reload this page.
srittau commentedMay 9, 2025
This is the only remaining blocker for supporting Python 3.14 in typeshed (python/typeshed#13957). Is a release with this fix planned in the next few days? Otherwise I'd try to install mypy directly from GitHub in typeshed's CI. |
hauntsaninja commentedMay 9, 2025
There are rumours of a release soon in#18739 But doesn't really hurt to install mypy directly from master... we've done it so many times in typeshed history |
This PR:- adds the missing `py.typed` marker file that indicates to consumersthat the code has usable type hints- moves type checks to the test job of `on-commit` GitHub Actionsworkflow, instead of the style job. (Those type checks arePython-version dependent, and we want our type hints to be valid for allsupported Python versions.)- fixes type hints to be Python 3.8-compatible on the`fraction_to_float.py` scriptNote: we're hitting a (known, fixed in main) issue with mypy and Python3.14, so we skip the type check on Python 3.14 for now. xref:python/mypy#19020
python/cpython#132323 added an optional
colorargument to ArgumentParser. As a side effect the help formatters are now called with two new keyword argumentsprefix_charsandcolor. Add**kwargsto the customAugmentedHelpFormatterand pass it through to the super class.