From 884e0ed756b0d46f23dd28d00805cbe6a16f86f1 Mon Sep 17 00:00:00 2001 From: Thomas Kluyver Date: Tue, 2 Aug 2022 09:57:28 +0100 Subject: [PATCH 1/2] Run style checks separate from test suite --- .github/workflows/tests.yml | 4 ++-- dev-requirements.txt | 1 - tox.ini | 4 ++++ 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 3dc93ec..aea19d3 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -6,7 +6,7 @@ env: FORCE_COLOR: 1 jobs: - isort: + static-checks: runs-on: ubuntu-latest steps: @@ -23,7 +23,7 @@ jobs: pip install tox tox-venv - name: Run tests - run: tox -e isort + run: tox -e isort,flake8 tests: runs-on: ${{ matrix.os }} diff --git a/dev-requirements.txt b/dev-requirements.txt index 1384c9c..bbdcf37 100644 --- a/dev-requirements.txt +++ b/dev-requirements.txt @@ -1,5 +1,4 @@ pytest -pytest-flake8 flake8 testpath tomli diff --git a/tox.ini b/tox.ini index 3bb2f36..00b1010 100644 --- a/tox.ini +++ b/tox.ini @@ -12,6 +12,10 @@ commands = pytest [] deps = isort commands = python -m isort --check --diff {toxinidir} +[testenv:flake8] +deps = flake8 +commands = flake8 pep517 + [testenv:release] skip_install = True deps = From a29513a03d60a90c048ad9281dd7e897bd6f40b1 Mon Sep 17 00:00:00 2001 From: Thomas Kluyver Date: Tue, 2 Aug 2022 09:59:39 +0100 Subject: [PATCH 2/2] Don't use --flake8 option for pytest --- pytest.ini | 3 --- 1 file changed, 3 deletions(-) diff --git a/pytest.ini b/pytest.ini index 7d86c9c..bbc5c14 100644 --- a/pytest.ini +++ b/pytest.ini @@ -2,10 +2,7 @@ addopts = --strict-config --strict-markers - --flake8 xfail_strict = True junit_family = xunit2 filterwarnings = error - # Suppress deprecation warning in flake8 - ignore:SelectableGroups dict interface is deprecated::flake8