jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/505266 )
Change subject: [tests] Ignore flake8-quotes error Q003 ......................................................................
[tests] Ignore flake8-quotes error Q003
Ignore flake8-quotes error Q003: Change outer quotes to avoid escaping inner quotes for related files until this issue is solved upstream.
Bug: T221462 Change-Id: I0b2f2d1469108f4f6ad46b11f92783a091fd77f2 --- M scripts/maintenance/diff_checker.py M tox.ini 2 files changed, 12 insertions(+), 7 deletions(-)
Approvals: D3r1ck01: Looks good to me, approved jenkins-bot: Verified
diff --git a/scripts/maintenance/diff_checker.py b/scripts/maintenance/diff_checker.py index 1bc2727..1dc9b3b 100644 --- a/scripts/maintenance/diff_checker.py +++ b/scripts/maintenance/diff_checker.py @@ -17,12 +17,13 @@ python release. """ # -# (C) Pywikibot team, 2017-2018 +# (C) Pywikibot team, 2017-2019 # # Distributed under the terms of the MIT license. #
-from __future__ import absolute_import, division, unicode_literals +from __future__ import ( + absolute_import, division, print_function, unicode_literals)
from re import compile as re_compile, IGNORECASE from subprocess import check_output @@ -61,7 +62,7 @@
def print_error(path, line_no, col_no, error): """Print the error.""" - print('{0}:{1}:{2}: {3}'.format(path, line_no, col_no, error)) + print('{}:{}:{}: {}'.format(path, line_no, col_no, error)) # noqa: T001
def check_quotes(match, file_path, start): diff --git a/tox.ini b/tox.ini index 8dbf4ae..48c0edd 100644 --- a/tox.ini +++ b/tox.ini @@ -104,6 +104,9 @@ # D412: No blank lines allowed between a section header and its content # D413: Missing blank line after last section
+# Error introduced with flake8-quotes 2.0.0 +# Q003: Change outer quotes to avoid escaping inner quotes + ignore = D105,D211,D401,D413,D412,FI12,FI13,FI15,FI16,FI17,FI5,H101,H236,H301,H404,H405,H903,P101,P102,P103,W503 enable-extensions = H203,H204,H205 exclude = .tox,.git,./*.egg,build,user-config.py,./scripts/i18n/*,scripts/userscripts/* @@ -152,9 +155,9 @@ pywikibot/login.py: N802, N816 pywikibot/page.py: N802 pywikibot/pagegenerators.py : N802, N803, N806, N816 - pywikibot/site.py: N802, N815 + pywikibot/site.py: N802, N815, Q003 pywikibot/specialbots.py : N803, N806, N802 - pywikibot/textlib.py : N801, N802, N803, N806, N816 + pywikibot/textlib.py : N801, N802, N803, N806, N816, Q003 pywikibot/throttle.py: N802 pywikibot/tools/_logging.py: N802 pywikibot/tools/ip.py : N803, N802 @@ -192,6 +195,7 @@ scripts/interwiki.py : N802, N803, N806, N816 scripts/isbn.py : N802, N803, N806, N816 scripts/maintenance/* : T001 + scripts/maintenance/diff_checker.py : Q003 scripts/maintenance/download_dump.py : N815 scripts/match_images.py : N803, N806 scripts/misspelling.py : N802, N803, N806, N815 @@ -223,7 +227,7 @@ tests/edit_failure_tests.py: N802 tests/exceptions_tests.py: N802 tests/family_tests.py: N802, N813 - tests/file_tests.py: N802, N813 + tests/file_tests.py: N802, N813, Q003 tests/flow_edit_tests.py: N813 tests/flow_tests.py: N813 tests/http_tests.py: N813 @@ -231,7 +235,7 @@ tests/imagecopy_tests.py: N802 tests/interwiki_link_tests.py: N802 tests/isbn_tests.py: N802 - tests/link_tests.py: N802 + tests/link_tests.py: N802, Q003 tests/logentry_tests.py: N802, N813 tests/login_tests.py: N802 tests/namespace_tests.py: N802, N813