From fd6ecec1d273c418f15fca7f6765bf8f6b9cbff5 Mon Sep 17 00:00:00 2001 From: Vojtech Trefny Date: Tue, 3 Oct 2023 11:43:28 +0200 Subject: [PATCH 1/2] pylint: Use 'exit' instead of 'do_exit' for pylint.lint.Run The 'do_exit' keyword argument has been deprecated for a while and finally removed in pylinr 3.0. --- tests/pylint/censorship.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/pylint/censorship.py b/tests/pylint/censorship.py index 30b0d4dab..33ed42dc9 100755 --- a/tests/pylint/censorship.py +++ b/tests/pylint/censorship.py @@ -109,7 +109,7 @@ def run(self): pylint.lint.Run(args, reporter=TextReporter(self._stdout), - do_exit=False) + exit=False) return self._process_output() From c342e465fa04287f59c5877cc3229fa041fdd7f8 Mon Sep 17 00:00:00 2001 From: Vojtech Trefny Date: Tue, 3 Oct 2023 12:04:47 +0200 Subject: [PATCH 2/2] tests: Ignore new pylint false positive with pylint 3.0 --- tests/run_tests.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/run_tests.py b/tests/run_tests.py index 792fd2b03..a49f6736e 100644 --- a/tests/run_tests.py +++ b/tests/run_tests.py @@ -86,8 +86,8 @@ def _should_skip(distro=None, version=None, arch=None, reason=None): # pylint: # DISTRO, VERSION and ARCH variables are set in main, we don't need to # call hostnamectl etc. for every test run - if (distro is None or DISTRO in distro) and (version is None or VERSION in version) and \ - (arch is None or ARCH in arch): + if ((distro is None or DISTRO in distro) and (version is None or VERSION in version) and # pylint: disable=used-before-assignment + (arch is None or ARCH in arch)): # pylint: disable=used-before-assignment return True return False