Skip to content
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

Make it possible to ignore annotations in certain files/directories #562

Closed
JukkaL opened this issue Jan 25, 2015 · 3 comments
Closed

Make it possible to ignore annotations in certain files/directories #562

JukkaL opened this issue Jan 25, 2015 · 3 comments

Comments

@JukkaL
Copy link
Collaborator

JukkaL commented Jan 25, 2015

Maybe we need a configuration option to force certain modules to not be type checked (this would also allow arbitrary expressions in function annotations). This might be useful for legacy code that uses annotations -- and also for legacy code in general. The configuration option could be command line argument or a setting in a mypy configuration file, for example. By default, we could enable this for the Python std lib.

This was mentioned on python-ideas when discussing PEP 484.

An older idea is to not type check modules that don't import typing, but maybe that is too restrictive -- again, this was mentioned in the PEP 484 discussion.

@JukkaL JukkaL changed the title Make it possible to ignore annotation in certain files/directories Make it possible to ignore annotations in certain files/directories Jan 28, 2015
@JelleZijlstra
Copy link
Member

Config files now support an ignore_errors = True option to ignore all errors in a file, so I think this can be closed.

@gvanrossum
Copy link
Member

No, pep 484 specifies# type: ignore which is still not implemented.

@JelleZijlstra
Copy link
Member

Then this is a dupe of #626.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants