From 6e89a16f1fda8a230f6e03ccb11274ec1fe796dc Mon Sep 17 00:00:00 2001 From: Myrausman Date: Thu, 10 Oct 2024 19:28:06 +0500 Subject: [PATCH 1/3] Refactor GitHub Actions workflow to support multiple Python versions Signed-off-by: Myrausman --- .github/workflows/python-app.yml | 19 +++++++++++++++---- .github/workflows/tests.yml | 18 +++++++++++++----- 2 files changed, 28 insertions(+), 9 deletions(-) diff --git a/.github/workflows/python-app.yml b/.github/workflows/python-app.yml index 95c39fad..d7a47d66 100644 --- a/.github/workflows/python-app.yml +++ b/.github/workflows/python-app.yml @@ -9,24 +9,35 @@ on: jobs: build: runs-on: ubuntu-latest + strategy: + matrix: + python-version: ['3.6', '3.8', '3.10', '3.12'] + steps: - uses: actions/checkout@v2 - - name: Set up Python 3.8 + + - name: Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v2 with: - python-version: 3.8 - - name: Install Coverage + python-version: ${{ matrix.python-version }} + + - name: Install PyYAML run: | pip3 install coverage + - name: Run pre-commit run: | python3 -m pip install pre-commit pre-commit run --all-files + - name: Generate run: coverage run ./parse.py -c -chisel -sverilog -rust -latex -spinalhdl -go "rv*" "unratified/rv*" + - name: Check C output - run: cat encoding.out.h | cpp + run: cat encoding.out.h | cpp + - name: Generate coverage run: coverage xml + - name: Upload coverage uses: codecov/codecov-action@v2 diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 0eb0c898..b32a1dd1 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -9,18 +9,26 @@ on: jobs: build: runs-on: ubuntu-latest + strategy: + matrix: + python-version: ['3.6', '3.8', '3.10', '3.12'] + steps: - uses: actions/checkout@v2 - - name: Set up Python 3.8 + + - name: Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v2 with: - python-version: 3.8 - - name: Install Coverage + python-version: ${{ matrix.python-version }} + + - name: Install dependencies run: | pip3 install coverage - name: Test error outputs run: coverage run -m unittest -b - - name: Generate coverage + + - name: Generate coverage report run: coverage xml - - name: Upload coverage + + - name: Upload coverage report uses: codecov/codecov-action@v2 From 24fd807d1380a5134669ec67483dc100500939f1 Mon Sep 17 00:00:00 2001 From: Myrausman Date: Thu, 24 Oct 2024 17:07:49 +0500 Subject: [PATCH 2/3] CI improvements --- .github/workflows/python-app.yml | 2 +- .github/workflows/tests.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/python-app.yml b/.github/workflows/python-app.yml index d7a47d66..35d4166a 100644 --- a/.github/workflows/python-app.yml +++ b/.github/workflows/python-app.yml @@ -11,7 +11,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: ['3.6', '3.8', '3.10', '3.12'] + python-version: ['3.9', '3.10', '3.11', '3.12','3.13'] steps: - uses: actions/checkout@v2 diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index b32a1dd1..5a188730 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -11,7 +11,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: ['3.6', '3.8', '3.10', '3.12'] + python-version: ['3.9', '3.10', '3.11', '3.12','3.13'] steps: - uses: actions/checkout@v2 From 5866a6007d85abb70dad3ea3fa3bfde6477fc503 Mon Sep 17 00:00:00 2001 From: Jay Dev Jha Date: Tue, 5 Nov 2024 15:41:16 +0530 Subject: [PATCH 3/3] MInor update python-app.yml Signed-off-by: Jay Dev Jha --- .github/workflows/python-app.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/python-app.yml b/.github/workflows/python-app.yml index 35d4166a..6efaaece 100644 --- a/.github/workflows/python-app.yml +++ b/.github/workflows/python-app.yml @@ -21,7 +21,7 @@ jobs: with: python-version: ${{ matrix.python-version }} - - name: Install PyYAML + - name: Install Coverage run: | pip3 install coverage