-
-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Update to typed-ast 1.0.0 #2857
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
Conversation
d8f09b2
to
8c23122
Compare
mypy/fastparse.py
Outdated
@@ -27,7 +27,7 @@ | |||
from mypy.errors import Errors | |||
|
|||
try: | |||
from typed_ast import ast35 | |||
from typed_ast import ast3 # type: ignore |
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.
I'm guessing the typeshed stubs for typed_ast need an update? I can work on that if you're not already doing it.
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.
Awesome! Just a process nit (we need to remember to update the stubs), and waiting for the failing test to be fixed. We also need to fix docs/source/python36.rst before releasing mypy 0.480.
mypy/fastparse.py
Outdated
@@ -120,7 +120,7 @@ def is_no_type_check_decorator(expr: ast3.expr) -> bool: | |||
return False | |||
|
|||
|
|||
class ASTConverter(ast3.NodeTransformer): | |||
class ASTConverter(ast3.NodeTransformer): # type: ignore |
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.
Can you open a typeshed issue to upgrade the typed_ast stubs, and link this (and similer ignores later) to it?
Typeshed PR here: python/typeshed#931 |
Whee! I'll leave the typeshed sync and the removal of the ignores for a later PR. |
The new version of typed-ast supports all Python 3.6 syntax features. This unblocks #2622. The new version of typed_ast also supports type comments on
async with
andasync for
, support for which will be added in a subsequent PR.