From fc4dde8d3a31523d9e451c025352a92a9749b901 Mon Sep 17 00:00:00 2001 From: George Date: Thu, 16 Mar 2023 02:46:51 +0000 Subject: [PATCH] (3.8) Minor tweaks (#368) --- bugbear.py | 2 +- pyproject.toml | 2 +- tests/test_bugbear.py | 6 ++---- tox.ini | 2 +- 4 files changed, 5 insertions(+), 7 deletions(-) diff --git a/bugbear.py b/bugbear.py index 5fac11a..7940120 100644 --- a/bugbear.py +++ b/bugbear.py @@ -135,7 +135,7 @@ def add_options(optmanager): help="Skip B008 test for additional immutable calls.", ) - @lru_cache() # noqa: B019 + @lru_cache # noqa: B019 def should_warn(self, code): """Returns `True` if Bugbear should emit a particular warning. diff --git a/pyproject.toml b/pyproject.toml index fb6904f..5803d25 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -34,7 +34,7 @@ classifiers = [ "Topic :: Software Development :: Libraries :: Python Modules", "Topic :: Software Development :: Quality Assurance", ] -requires-python = ">=3.8" +requires-python = ">=3.8.1" dependencies = ["flake8 >= 3.0.0", "attrs>=19.2.0"] dynamic = ["version"] diff --git a/tests/test_bugbear.py b/tests/test_bugbear.py index 8964c5e..1114e83 100644 --- a/tests/test_bugbear.py +++ b/tests/test_bugbear.py @@ -747,8 +747,7 @@ def test_selfclean_bugbear(self): filename = Path(__file__).absolute().parent.parent / "bugbear.py" proc = subprocess.run( ["flake8", str(filename)], - stdout=subprocess.PIPE, - stderr=subprocess.PIPE, + capture_output=True, timeout=60, ) self.assertEqual(proc.returncode, 0, proc.stdout.decode("utf8")) @@ -759,8 +758,7 @@ def test_selfclean_test_bugbear(self): filename = Path(__file__).absolute() proc = subprocess.run( ["flake8", str(filename)], - stdout=subprocess.PIPE, - stderr=subprocess.PIPE, + capture_output=True, timeout=60, ) self.assertEqual(proc.returncode, 0, proc.stdout.decode("utf8")) diff --git a/tox.ini b/tox.ini index e05fa88..361c1dc 100644 --- a/tox.ini +++ b/tox.ini @@ -10,7 +10,7 @@ python = 3.10: py310 3.11: py311 -[testenv:{py37, py38, py39, py310, py311}] +[testenv:{py38, py39, py310, py311}] description = Run coverage deps = coverage