From b5848da18821a1679524b3efc798946ffcc26c79 Mon Sep 17 00:00:00 2001 From: Arnaud Date: Thu, 9 Jan 2025 12:58:58 +0100 Subject: [PATCH] Use Ubuntu 20.04 for coverage --- .github/actions/nimbus-build-system/action.yml | 4 ++-- .github/workflows/ci-reusable.yml | 1 + .github/workflows/ci.yml | 7 ++++++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/actions/nimbus-build-system/action.yml b/.github/actions/nimbus-build-system/action.yml index 2a70e39de..67ad6c986 100644 --- a/.github/actions/nimbus-build-system/action.yml +++ b/.github/actions/nimbus-build-system/action.yml @@ -85,8 +85,8 @@ runs: pacman -U --noconfirm https://repo.msys2.org/mingw/ucrt64/mingw-w64-ucrt-x86_64-gcc-14.2.0-2-any.pkg.tar.zst https://repo.msys2.org/mingw/ucrt64/mingw-w64-ucrt-x86_64-gcc-libs-14.2.0-2-any.pkg.tar.zst - name: Install gcc 14 on Linux - # Should be removed when ubuntu-latest is 26.04 - if : ${{ inputs.os == 'linux' }} + # We don't want to install gcc 14 for coverage (Ubuntu 20.04) + if : ${{ inputs.os == 'linux' && !inputs.coverage }} shell: ${{ inputs.shell }} {0} run: | # Add GCC-14 to alternatives diff --git a/.github/workflows/ci-reusable.yml b/.github/workflows/ci-reusable.yml index 55846d898..ce66a9b66 100644 --- a/.github/workflows/ci-reusable.yml +++ b/.github/workflows/ci-reusable.yml @@ -40,6 +40,7 @@ jobs: os: ${{ matrix.os }} shell: ${{ matrix.shell }} nim_version: ${{ matrix.nim_version }} + coverage: false ## Part 1 Tests ## - name: Unit tests diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a79c38dd7..9b865de66 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -48,7 +48,11 @@ jobs: cache_nonce: ${{ needs.matrix.outputs.cache_nonce }} coverage: - runs-on: ubuntu-latest + # Force to stick to ubuntu 20.04 for coverage because + # lcov was updated to 2.x version in ubuntu-latest + # and cause a lot of issues. + # See https://github.com/linux-test-project/lcov/issues/238 + runs-on: ubuntu-20.04 steps: - name: Checkout sources uses: actions/checkout@v4 @@ -61,6 +65,7 @@ jobs: with: os: linux nim_version: ${{ env.nim_version }} + coverage: true - name: Generate coverage data run: |