Skip to content

Add a type: ignore as a hacky workaround for some mypy bazel issues#2887

Merged
JelleZijlstra merged 1 commit intomasterfrom
ast-asdf
Mar 27, 2019
Merged

Add a type: ignore as a hacky workaround for some mypy bazel issues#2887
JelleZijlstra merged 1 commit intomasterfrom
ast-asdf

Conversation

@msullivan
Copy link
Contributor

No description provided.

@msullivan msullivan requested a review from gvanrossum March 26, 2019 23:20
@JelleZijlstra
Copy link
Member

I'm OK with this, but pytype apparently doesn't like # type: ignore in this position.

@gvanrossum
Copy link
Member

We noticed. :-) Maybe pytype doesn't like # type: ignore on import *? Because there are non-star imports with # type: ignore.

@rchen152
Copy link
Collaborator

Looks like pytype doesn't like # type: ignore on import lines at all. (Maybe the ones you saw were in the parts of third_party that pytype ignores?) I've mailed a fix out for review, will hopefully be able to release it tomorrow.

rchen152 added a commit to google/pytype that referenced this pull request Mar 27, 2019
Our parser is causing problems for
python/typeshed#2887 (comment).

Most of the new tests call parse_string() directly instead of using
_ParserTestBase.check() because the ast contains internal details
like the use of __PACKAGE__ for the current package.

PiperOrigin-RevId: 240610622
@rchen152
Copy link
Collaborator

The pytype issue was fixed in pytype 2019.03.27.

@JelleZijlstra
Copy link
Member

Thanks @rchen152!

@JelleZijlstra JelleZijlstra merged commit cc596ae into master Mar 27, 2019
@JelleZijlstra JelleZijlstra deleted the ast-asdf branch March 27, 2019 22:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants