From 0bc6f5ac761faf587538b52631036adce72935f4 Mon Sep 17 00:00:00 2001 From: Adeeb Shihadeh Date: Sat, 17 Aug 2024 10:15:04 -0700 Subject: [PATCH 1/7] speeeeed --- .github/workflows/tests.yml | 21 ++------------------- 1 file changed, 2 insertions(+), 19 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 711059405b..3e35e2e156 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -27,22 +27,5 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - name: Build Docker image - run: eval "$BUILD" - - name: pre-commit - # TODO: a package pre-commit installs has a warning, remove the unset once that's fixed - run: ${{ env.RUN }} "git init && git add -A && unset PYTHONWARNINGS && pre-commit run --all" - - docker-push: - name: docker push - runs-on: ubuntu-latest - if: github.ref == 'refs/heads/master' && github.event_name != 'pull_request' && github.repository == 'commaai/opendbc' - steps: - - uses: actions/checkout@v4 - - name: Build Docker image - run: eval "$BUILD" - - name: Push to dockerhub - run: | - docker login ghcr.io -u ${{ github.actor }} -p ${{ secrets.GITHUB_TOKEN }} - docker tag opendbc ghcr.io/commaai/opendbc:latest - docker push ghcr.io/commaai/opendbc:latest + - uses: actions/setup-python@v5 + - uses: pre-commit/action@v3.0.1 From 3ae079108c253eae707de0fdd5ccb456f9c2c222 Mon Sep 17 00:00:00 2001 From: Adeeb Shihadeh Date: Sat, 17 Aug 2024 10:17:08 -0700 Subject: [PATCH 2/7] version --- .github/workflows/tests.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 3e35e2e156..f39e5c3eb3 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -28,4 +28,6 @@ jobs: steps: - uses: actions/checkout@v4 - uses: actions/setup-python@v5 + with: + python-version: '3.11' - uses: pre-commit/action@v3.0.1 From 3119b59b2efae662960b4d532b06bd75fe361b6a Mon Sep 17 00:00:00 2001 From: Adeeb Shihadeh Date: Sat, 17 Aug 2024 10:18:59 -0700 Subject: [PATCH 3/7] disable --- .github/workflows/tests.yml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index f39e5c3eb3..ea395cc730 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -1,11 +1,15 @@ name: tests -on: [push, pull_request] +on: + push: + branches: + - master + pull_request: env: RUN: docker run -e PYTHONWARNINGS="error,default::DeprecationWarning" --shm-size 1G --rm opendbc /bin/bash -c BUILD: docker buildx build --pull --load --cache-to type=inline --cache-from type=registry,ref=ghcr.io/commaai/opendbc:latest -t opendbc -f Dockerfile . - PYTHONWARNINGS: error + #PYTHONWARNINGS: error jobs: unit-tests: From 22af43644ec3bc4f3dab964963676d924650d989 Mon Sep 17 00:00:00 2001 From: Adeeb Shihadeh Date: Sat, 17 Aug 2024 10:20:42 -0700 Subject: [PATCH 4/7] cppcheck --- .github/workflows/tests.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index ea395cc730..6ae770e436 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -34,4 +34,5 @@ jobs: - uses: actions/setup-python@v5 with: python-version: '3.11' + - run: sudo apt update && sudo apt install --no-install-recommends -y cppcheck - uses: pre-commit/action@v3.0.1 From f39ac58ea024e0946cd997a5f900971568cefd35 Mon Sep 17 00:00:00 2001 From: Adeeb Shihadeh Date: Sat, 17 Aug 2024 10:22:28 -0700 Subject: [PATCH 5/7] pip install --- .github/workflows/tests.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 6ae770e436..fd7f0e4c1f 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -35,4 +35,5 @@ jobs: with: python-version: '3.11' - run: sudo apt update && sudo apt install --no-install-recommends -y cppcheck + - run: pip install -e . - uses: pre-commit/action@v3.0.1 From a7f27b21f816a0438763b3d42821b5bdb466e35e Mon Sep 17 00:00:00 2001 From: Adeeb Shihadeh Date: Sat, 17 Aug 2024 10:24:14 -0700 Subject: [PATCH 6/7] no update? --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index fd7f0e4c1f..358f809361 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -34,6 +34,6 @@ jobs: - uses: actions/setup-python@v5 with: python-version: '3.11' - - run: sudo apt update && sudo apt install --no-install-recommends -y cppcheck + - run: sudo apt install --no-install-recommends -y cppcheck - run: pip install -e . - uses: pre-commit/action@v3.0.1 From 36bb35f8176d74f81bf8156c2604d01ba283177c Mon Sep 17 00:00:00 2001 From: Adeeb Shihadeh Date: Sat, 17 Aug 2024 10:26:54 -0700 Subject: [PATCH 7/7] timeout --- .github/workflows/tests.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 358f809361..93fbbb4c68 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -9,12 +9,13 @@ on: env: RUN: docker run -e PYTHONWARNINGS="error,default::DeprecationWarning" --shm-size 1G --rm opendbc /bin/bash -c BUILD: docker buildx build --pull --load --cache-to type=inline --cache-from type=registry,ref=ghcr.io/commaai/opendbc:latest -t opendbc -f Dockerfile . - #PYTHONWARNINGS: error + PYTHONWARNINGS: error jobs: unit-tests: name: unit tests runs-on: ubuntu-latest + timeout-minutes: 1 #strategy: # fail-fast: false # matrix: @@ -29,6 +30,10 @@ jobs: static-analysis: name: static analysis runs-on: ubuntu-latest + timeout-minutes: 1 + env: + # package install has DeprecationWarnings + PYTHONWARNINGS: default steps: - uses: actions/checkout@v4 - uses: actions/setup-python@v5