From 3dab0e9d914d70879d2ab8864c97a4721ffcf96e Mon Sep 17 00:00:00 2001 From: Athanasius Date: Fri, 31 Jul 2020 14:44:44 +0100 Subject: [PATCH] Comment pr-check flake8, and don't --exit-zero the full check --- .github/workflows/pr-checks.yml | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/workflows/pr-checks.yml b/.github/workflows/pr-checks.yml index 4e0a0a79..f39bb335 100644 --- a/.github/workflows/pr-checks.yml +++ b/.github/workflows/pr-checks.yml @@ -75,8 +75,13 @@ jobs: BASE_REF: ${{github.base_ref}} run: | - # stop the build if there are Python syntax errors or undefined names, ignore existing + # Explicitly check for some errors + # E9 - Runtime (syntax and the like) + # F63 - 'tests' checking + # F7 - syntax errors + # F82 - undefined checking git diff "refs/remotes/${BASE_REPO_OWNER}/${BASE_REF}" -- | flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics --diff - # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide - git diff "refs/remotes/${BASE_REPO_OWNER}/${BASE_REF}" -- | flake8 . --count --exit-zero --statistics --diff + # Can optionally add `--exit-zero` to the flake8 arguments so that + # this doesn't fail the build. + git diff "refs/remotes/${BASE_REPO_OWNER}/${BASE_REF}" -- | flake8 . --count --statistics --diff ####################################################################