-
Notifications
You must be signed in to change notification settings - Fork 81
Fix ci: pin linux, pin flake8, ignore type error, fix mypy #308
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -26,6 +26,8 @@ command line:: | |
|
|
||
| $ stone -h | ||
|
|
||
| Stone requires Python 3. | ||
|
|
||
| Alternative | ||
| ----------- | ||
|
|
||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,5 +1,4 @@ | ||
| [mypy] | ||
| # follow_imports = False | ||
| ignore_missing_imports = True | ||
| show_none_errors = True | ||
| strict_optional = True |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -9,19 +9,13 @@ | |
| try: | ||
| from inspect import getfullargspec as get_args | ||
| except ImportError: | ||
| from inspect import getargspec as get_args | ||
| from inspect import getargspec as get_args # type: ignore | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks |
||
|
|
||
| _MYPY = False | ||
| if _MYPY: | ||
| import typing # noqa: F401 # pylint: disable=import-error,unused-import,useless-suppression | ||
|
|
||
| # Hack to get around some of Python 2's standard library modules that | ||
| # accept ascii-encodable unicode literals in lieu of strs, but where | ||
| # actually passing such literals results in errors with mypy --py2. See | ||
| # <https://github.com/python/typeshed/issues/756> and | ||
| # <https://github.com/python/mypy/issues/2536>. | ||
| import importlib | ||
| re = importlib.import_module(str('re')) # type: typing.Any | ||
| import re | ||
|
|
||
| from ..ir import ( | ||
| Alias, | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -27,7 +27,7 @@ | |
| from test.backend_test_util import _mock_output | ||
|
|
||
|
|
||
| def _make_backend(target_folder_path, template_path, custom_args=None): | ||
| def _make_backend(target_folder_path, template_path, custom_args=None): # type: ignore | ||
| # type: (typing.Text, typing.Text, typing.List) -> TSDTypesBackend | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not for the sake of this PR, but we should be able to update these to modern type hint syntax right?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah, I'll run this one day: https://github.com/ilevkivskyi/com2ann
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Then we'll be able to unpin flake8 |
||
|
|
||
| args = Mock() | ||
|
|
||
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.
😍 love to see this.