From da71c7fac6853a3ad296d21602e4a71ab2c1123b Mon Sep 17 00:00:00 2001 From: 1-Bort-1 <323661610+1-Bort-1@users.noreply.github.com> Date: Fri, 11 Sep 2026 23:24:33 +0200 Subject: [PATCH 1/2] ci: fold the coverage job into the test matrix, macOS on push only Coverage now rides on the ubuntu 1.12 entry of `test` rather than a second job running the same suite instrumented on both Julia versions, and the macOS-latest/aarch64 entry is only present when the event is not a pull request. Both `test` entries move from actions/cache@v6 (artifacts only, keyed on Project.toml) to julia-actions/cache@v2. Non-draft pull requests go from 7 jobs to 4; push to main and tags keep the full matrix. Co-Authored-By: Claude Opus 5 Claude-Session: https://claude.ai/code/session_014ckETMPNKF5pHg5vYSx7XZ --- .github/workflows/CI.yml | 82 ++++++++++------------------------------ 1 file changed, 21 insertions(+), 61 deletions(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index f335e115..c608d965 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -17,7 +17,7 @@ jobs: name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }} if: github.event_name != 'pull_request' || github.event.pull_request.draft == false runs-on: ${{ matrix.os }} - timeout-minutes: 40 + timeout-minutes: 50 strategy: fail-fast: false matrix: @@ -26,19 +26,17 @@ jobs: - '1.12' os: - ubuntu-latest - build_is_production_build: - - true arch: - x64 - include: - - os: windows-latest - arch: x64 - version: '1.12' - build_is_production_build: true - - os: macOS-latest - arch: aarch64 - version: '1.12' - build_is_production_build: true + # macOS-aarch64 has no code of its own here and is the scarcest hosted pool, + # so pull requests get every entry but that one. + include: >- + ${{ github.event_name == 'pull_request' + && fromJSON('[{"os":"ubuntu-latest","version":"1.12","coverage":true}, + {"os":"windows-latest","arch":"x64","version":"1.12"}]') + || fromJSON('[{"os":"ubuntu-latest","version":"1.12","coverage":true}, + {"os":"windows-latest","arch":"x64","version":"1.12"}, + {"os":"macOS-latest","arch":"aarch64","version":"1.12"}]') }} steps: - uses: actions/checkout@v7 - uses: julia-actions/setup-julia@v3 @@ -50,64 +48,26 @@ jobs: run: | sudo apt-get update sudo apt-get install -y xvfb libgl1-mesa-dri - - uses: actions/cache@v6 - env: - cache-name: cache-artifacts - with: - path: ~/.julia/artifacts - key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }} - restore-keys: | - ${{ runner.os }}-test-${{ env.cache-name }}- - ${{ runner.os }}-test- - ${{ runner.os }}- + - uses: julia-actions/cache@v2 - uses: julia-actions/julia-buildpkg@v1 - uses: julia-actions/julia-runtest@v1 env: - BUILD_IS_PRODUCTION_BUILD: ${{ matrix.build_is_production_build }} + BUILD_IS_PRODUCTION_BUILD: true # Only Linux gets a virtual display, so runtests.jl skips the plotting tests # elsewhere. Julia 1.12.7 precompiles the whole test environment up front, # which loads GLMakie before that guard runs; keep it lazy off Linux. JULIA_PKG_PRECOMPILE_AUTO: ${{ runner.os == 'Linux' && '1' || '0' }} with: - coverage: false + coverage: ${{ matrix.coverage || false }} prefix: ${{ runner.os == 'Linux' && 'xvfb-run -a' || '' }} - test-with-code-coverage: - name: Julia ${{ matrix.julia_version }} - ${{ matrix.os }} - ${{ matrix.julia_arch }} - with code coverage - timeout-minutes: 50 - strategy: - fail-fast: false - matrix: - julia_version: - - "1.11" - - "1.12" - julia_arch: - - x64 - os: - - ubuntu-latest - runs-on: ${{ matrix.os }} - steps: - - uses: actions/checkout@v7 - - uses: julia-actions/setup-julia@v3 - with: - arch: ${{ matrix.julia_arch }} - version: ${{ matrix.julia_version }} - - name: Install display dependencies for GLMakie - run: | - sudo apt-get update - sudo apt-get install -y xvfb libgl1-mesa-dri - - uses: julia-actions/cache@v2 - - uses: julia-actions/julia-buildpkg@v1 - - uses: julia-actions/julia-runtest@v1 - env: - BUILD_IS_PRODUCTION_BUILD: false - with: - prefix: xvfb-run -a - - uses: julia-actions/julia-processcoverage@v1 - - uses: codecov/codecov-action@v7 - with: - token: ${{ secrets.CODECOV_TOKEN }} - files: lcov.info - continue-on-error: true + - uses: julia-actions/julia-processcoverage@v1 + if: matrix.coverage + - uses: codecov/codecov-action@v7 + if: matrix.coverage + with: + token: ${{ secrets.CODECOV_TOKEN }} + files: lcov.info + continue-on-error: true docs: name: Documentation runs-on: ubuntu-latest From 5df98ce40b7c2d1e5e765e14b96764b4c4c5ea91 Mon Sep 17 00:00:00 2001 From: 1-Bort-1 <323661610+1-Bort-1@users.noreply.github.com> Date: Sat, 12 Sep 2026 11:49:42 +0200 Subject: [PATCH 2/2] ci: keep the macOS-aarch64 entry on pull requests Co-Authored-By: Claude Opus 5 Claude-Session: https://claude.ai/code/session_01KVS7sbyoYtHatTcB9btGTh --- .github/workflows/CI.yml | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index c608d965..314bd3f1 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -28,15 +28,17 @@ jobs: - ubuntu-latest arch: - x64 - # macOS-aarch64 has no code of its own here and is the scarcest hosted pool, - # so pull requests get every entry but that one. - include: >- - ${{ github.event_name == 'pull_request' - && fromJSON('[{"os":"ubuntu-latest","version":"1.12","coverage":true}, - {"os":"windows-latest","arch":"x64","version":"1.12"}]') - || fromJSON('[{"os":"ubuntu-latest","version":"1.12","coverage":true}, - {"os":"windows-latest","arch":"x64","version":"1.12"}, - {"os":"macOS-latest","arch":"aarch64","version":"1.12"}]') }} + include: + # Merges into the ubuntu/1.12 combination rather than adding a job. + - os: ubuntu-latest + version: '1.12' + coverage: true + - os: windows-latest + arch: x64 + version: '1.12' + - os: macOS-latest + arch: aarch64 + version: '1.12' steps: - uses: actions/checkout@v7 - uses: julia-actions/setup-julia@v3