From 58b8801e4b7dd9ded2e3559bf68fbea5557894b2 Mon Sep 17 00:00:00 2001 From: LizardByte-bot <108553330+RetroArcher-bot@users.noreply.github.com> Date: Mon, 13 Feb 2023 16:20:58 +0000 Subject: [PATCH] ci: update global python --- .flake8 | 3 ++- .github/workflows/python-flake8.yml | 10 +++++++++- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/.flake8 b/.flake8 index 2ea7395..2d028b2 100644 --- a/.flake8 +++ b/.flake8 @@ -1,6 +1,7 @@ [flake8] filename = - *.py + *.py, + *.pys max-line-length = 120 extend-exclude = venv/ diff --git a/.github/workflows/python-flake8.yml b/.github/workflows/python-flake8.yml index 8769016..19bcdb9 100644 --- a/.github/workflows/python-flake8.yml +++ b/.github/workflows/python-flake8.yml @@ -1,7 +1,10 @@ +--- # This action is centrally managed in https://github.com//.github/ # Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in # the above-mentioned repo. +# Lint python files with flake8. + name: flake8 on: @@ -9,6 +12,10 @@ on: branches: [master, nightly] types: [opened, synchronize, reopened] +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + jobs: flake8: runs-on: ubuntu-latest @@ -23,7 +30,8 @@ jobs: - name: Install dependencies run: | - python -m pip install --upgrade pip setuptools flake8 + # pin flake8 before v6.0.0 due to removal of support for type comments (required for Python 2.7 type hints) + python -m pip install --upgrade pip setuptools "flake8<6" - name: Test with flake8 run: |