From f11301dc52ac39934312f213877b02b1aa95d416 Mon Sep 17 00:00:00 2001 From: Kyle Coble <53625197+Hackerman342@users.noreply.github.com> Date: Tue, 16 Jan 2024 18:54:07 -0500 Subject: [PATCH] Fix pre-commit check / format.yml workflow (#206) --- .github/workflows/format.yml | 19 +++++++++---------- .pre-commit-config.yaml | 4 ++-- 2 files changed, 11 insertions(+), 12 deletions(-) diff --git a/.github/workflows/format.yml b/.github/workflows/format.yml index 7af55f7e..7a916a0f 100644 --- a/.github/workflows/format.yml +++ b/.github/workflows/format.yml @@ -8,15 +8,14 @@ on: branches: - main +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} + cancel-in-progress: true + jobs: pre-commit-check: - runs-on: ubuntu-latest - steps: - - name: Checkout workspace - uses: actions/checkout@v3 - - name: Install pre-commit and install - run: | - pip install pre-commit - pre-commit install - - name: Run pre-commit checks - run: pre-commit run --all-files + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-python@v3 + - uses: pre-commit/action@v3.0.0 diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 2a59bb40..be23b01f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -13,11 +13,11 @@ repos: - id: check-json exclude: docs/.*$ - repo: https://github.com/pre-commit/mirrors-mypy - rev: "v1.5.1" + rev: "v1.8.0" hooks: - id: mypy args: ["--check-untyped-defs", "--ignore-missing-imports", "--explicit-package-bases"] - additional_dependencies: ["types-protobuf", "types-requests"] + additional_dependencies: ["types-protobuf==4.24.0.1", "types-requests"] - repo: https://github.com/Lucas-C/pre-commit-hooks rev: v1.1.13 hooks: