diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index dce4251..c56160a 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -6,12 +6,17 @@ on: pull_request: branches: [ main, master, develop ] +# Cancel in-progress runs when a new commit is pushed +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + jobs: test: runs-on: ubuntu-latest strategy: matrix: - python-version: ['3.11'] + python-version: ['3.10', '3.11', '3.12'] steps: - name: Checkout code @@ -54,7 +59,6 @@ jobs: run: | python activity_yaml_validator.py research/SPEC.yaml python activity_yaml_validator.py research/activity*.yaml - continue-on-error: true lint: runs-on: ubuntu-latest @@ -79,10 +83,13 @@ jobs: black --check --diff . continue-on-error: true - - name: Lint with flake8 + - name: Lint with flake8 (syntax errors) run: | # Stop the build if there are Python syntax errors or undefined names flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics + + - name: Lint with flake8 (style warnings) + run: | # Exit-zero treats all errors as warnings flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics continue-on-error: true