Skip to content

add "type: ignore" to lxml imports #4217

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

Merged
merged 1 commit into from
Nov 7, 2017
Merged

Conversation

JelleZijlstra
Copy link
Member

See python/typeshed#525 and python/typeshed#1664.

We decided to remove the lxml stubs because they cause problems so
frequently. However, this requires small tweaks to mypy's own usage
of lxml.

My plan is to proceed as follows:

  • Merge this PR, adding type ignores and removing warn_unused_ignores
    from mypy's self-check config.
  • Merge remove all lxml stubs for now typeshed#1664, which should pass Travis after his PR
    is merged.
  • Add "warn_unused_ignores" back to mypy's self-check config.

I confirmed that this PR passes tests both with and without the
lxml stubs being present.

See python/typeshed#525 and python/typeshed#1664.

We decided to remove the lxml stubs because they cause problems so
frequently. However, this requires small tweaks to mypy's own usage
of lxml.

My plan is to proceed as follows:
- Merge this PR, adding type ignores and removing warn_unused_ignores
  from mypy's self-check config.
- Merge python/typeshed#1664, which should pass Travis after his PR
  is merged.
- Add "warn_unused_ignores" back to mypy's self-check config.

I confirmed that this PR passes tests both with and without the
lxml stubs being present.
Copy link
Collaborator

@JukkaL JukkaL left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@JukkaL JukkaL merged commit 3f8ca34 into python:master Nov 7, 2017
JelleZijlstra added a commit that referenced this pull request Nov 7, 2017
JelleZijlstra added a commit that referenced this pull request Nov 7, 2017
gvanrossum pushed a commit that referenced this pull request Nov 7, 2017
Followup from #4217 and python/typeshed#1664.

Also had to change a few types to `Any` because of the missing lxml stubs.
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.

2 participants