Repository navigation
Run the MyPy pre-commit hook on Python 3.10 - #1546
Open
rodrigobnogueira wants to merge 1 commit into
Open
rodrigobnogueira wants to merge 1 commit into
rodrigobnogueira wants to merge 1 commit into
Conversation
MyPy 0.910 imports ast.Str, ast.Num and other names that Python 3.14 removed, and the failed import surfaces as "The typed_ast package is not installed". pre-commit.ci builds hook environments with Python 3.14, so the hook failed there. Run it on 3.10, as the Flake8 hook already does.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
pre-commit.ci fails on the MyPy hook with "The typed_ast package is not installed." It builds hook environments with Python 3.14, and MyPy 0.910, pinned through
mirrors-mypyv0.910, importsast.Str,ast.Numand other names that 3.14 removed; that failed import is what surfaces as thetyped_astmessage. On #1543 the failure was hidden: pre-commit.ci cut its output off inside Flake8's RST399 report, before the MyPy result.This runs the hook on Python 3.10, like the Flake8 hook already does, with a note saying when the pin can be dropped. The GitHub Actions lint job already runs pre-commit on Python 3.10, so its results do not change.
Until #1545 is merged, Flake8 still fails here, both on pre-commit.ci and in the lint job, and pre-commit.ci may cut its output off before the MyPy result again.
Part of #1544.