Replace # flake8: noqa with # noqa
The former syntax is actually a mis-use and rejected since Flake8 3.6 [1]. [1] https://gitlab.com/pycqa/flake8/merge_requests/219
This commit is contained in:
parent
61698f955e
commit
18173a5951
7 changed files with 69 additions and 69 deletions
|
|
@ -119,7 +119,7 @@ def append_mock_to_init_py(service):
|
|||
filtered_lines = [_ for _ in lines if re.match('^from.*mock.*$', _)]
|
||||
last_import_line_index = lines.index(filtered_lines[-1])
|
||||
|
||||
new_line = 'from .{} import mock_{} # flake8: noqa'.format(get_escaped_service(service), get_escaped_service(service))
|
||||
new_line = 'from .{} import mock_{} # noqa'.format(get_escaped_service(service), get_escaped_service(service))
|
||||
lines.insert(last_import_line_index + 1, new_line)
|
||||
|
||||
body = '\n'.join(lines) + '\n'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue