Xqt has submitted this change. ( https://gerrit.wikimedia.org/r/c/pywikibot/core/+/997900?usp=email )
Change subject: [tests] flake8-print namespace was changed from T0 to T2 ......................................................................
[tests] flake8-print namespace was changed from T0 to T2
change issue exceptions accordingly
Change-Id: I54ddfc80900752d13e930fbecd622cf3be889751 --- M pywikibot/scripts/shell.py M pywikibot/userinterfaces/_interface_base.py M scripts/maintenance/unidata.py M tests/__init__.py M tox.ini 5 files changed, 21 insertions(+), 10 deletions(-)
Approvals: Xqt: Verified; Looks good to me, approved
diff --git a/pywikibot/scripts/shell.py b/pywikibot/scripts/shell.py index 54520dc..399c5c4 100755 --- a/pywikibot/scripts/shell.py +++ b/pywikibot/scripts/shell.py @@ -44,7 +44,7 @@ warn_type = 'Unknown'
if args: - print('{} arguments: {}\n' # noqa: T001, T201 + print('{} arguments: {}\n' # noqa: T201 .format(warn_type, ', '.join(args)))
# Various stuffs in Python 3.4+, such as history file. diff --git a/pywikibot/userinterfaces/_interface_base.py b/pywikibot/userinterfaces/_interface_base.py index 2bc79ad..d754eeb 100644 --- a/pywikibot/userinterfaces/_interface_base.py +++ b/pywikibot/userinterfaces/_interface_base.py @@ -74,4 +74,4 @@ @abstractmethod def output(self, *args, **kwargs) -> None: """Output text to a stream.""" - print(*args, **kwargs) # noqa: T001, T201 + print(*args, **kwargs) # noqa: T201 diff --git a/scripts/maintenance/unidata.py b/scripts/maintenance/unidata.py index cb20643..5ca1c7a 100755 --- a/scripts/maintenance/unidata.py +++ b/scripts/maintenance/unidata.py @@ -138,7 +138,7 @@ with open(path, encoding='utf8') as f: return load(f) except OSError: - print('File not found:', path) # noqa: T001, T201 + print('File not found:', path) # noqa: T201 return {}
@@ -151,4 +151,4 @@ # families_excepts = load_json(FILEPATH) # main() # save_json(families_excepts, FILEPATH) - print(process_site('wiktionary', 'fr')) # noqa: T001, T201 + print(process_site('wiktionary', 'fr')) # noqa: T201 diff --git a/tests/__init__.py b/tests/__init__.py index c965467..7d6c1fc 100644 --- a/tests/__init__.py +++ b/tests/__init__.py @@ -198,7 +198,7 @@
def unittest_print(*args, **kwargs): """Print information in test log.""" - print(*args, **kwargs) # noqa: T001, T201 + print(*args, **kwargs) # noqa: T201
def collector(loader=unittest.loader.defaultTestLoader): diff --git a/tox.ini b/tox.ini index d7de29f..8ab5836 100644 --- a/tox.ini +++ b/tox.ini @@ -173,8 +173,8 @@ pywikibot/pagegenerators/__init__.py: N802 pywikibot/pagegenerators/_filters.py: N802 pywikibot/pagegenerators/_generators.py: N802 - pywikibot/scripts/generate_family_file.py: T001, T201 - pywikibot/scripts/wrapper.py: FI53, T001, T201 + pywikibot/scripts/generate_family_file.py: T201 + pywikibot/scripts/wrapper.py: FI53, T201 pywikibot/site/_datasite.py: N802 pywikibot/textlib.py: N801, N802, N803, N806 pywikibot/throttle.py: N802 @@ -191,14 +191,14 @@ scripts/harvest_template.py: N802, N816 scripts/interwiki.py: N802, N803, N806, N816 scripts/imagetransfer.py: N803, N806, N816 - scripts/maintenance/make_i18n_dict.py: T001, T201 + scripts/maintenance/make_i18n_dict.py: T201 scripts/misspelling.py: N802 scripts/noreferences.py: N802, N803, N806, N816 scripts/redirect.py: N803, N806 scripts/reflinks.py: N802, N816 scripts/replace.py: N802, N803, N806, N816 scripts/solve_disambiguation.py: N802, N806 - setup.py: T001, T201 + setup.py: T201 tests/api_tests.py: N802 tests/archivebot_tests.py: N802 tests/aspects.py: N802 @@ -215,7 +215,7 @@ tests/namespace_tests.py: N802 tests/page_tests.py: E241, N802 tests/pagegenerators_tests.py: N802 - tests/pwb/*: T001, T201 + tests/pwb/*: T201 tests/site_detect_tests.py: N802 tests/sparql_tests.py: N802 tests/textlib_tests.py: N802