From 2782c6e6a73bf822744a784e26b1ecac7afae2ff Mon Sep 17 00:00:00 2001 From: schnellerhase <56360279+schnellerhase@users.noreply.github.com> Date: Fri, 5 Dec 2025 21:46:35 +0100 Subject: [PATCH 1/5] Pull compiler from cache --- .github/actions/test-package/action.yml | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/.github/actions/test-package/action.yml b/.github/actions/test-package/action.yml index 340a7cb6..51ceb996 100644 --- a/.github/actions/test-package/action.yml +++ b/.github/actions/test-package/action.yml @@ -33,12 +33,20 @@ runs: - name: Install gcc-13 (default) shell: sh if: contains(inputs.spec, 'gcc@13') || (! contains(inputs.spec, 'clang') && ! contains(inputs.spec, 'gcc')) - run: apt-get install -y g++ gcc gfortran build-essential + # run: apt-get install -y g++ gcc gfortran build-essential + run: | + spack install --cache-only gcc@13 + spack compiler find $(spack location -i gcc) + spack compilers - name: Install clang-18 shell: sh if: contains(inputs.spec, 'clang@18') - run: apt-get install -y clang-18 gfortran + # run: apt-get install -y clang-18 gfortran + run: | + spack install --cache-only clang@13 + spack compiler find $(spack location -i clang) + spack compilers - name: Add repos shell: spack-bash {0} From c4d03bbf46cd07b22b05620cfb5007be2c5edef1 Mon Sep 17 00:00:00 2001 From: schnellerhase <56360279+schnellerhase@users.noreply.github.com> Date: Fri, 5 Dec 2025 21:47:27 +0100 Subject: [PATCH 2/5] on push --- .github/workflows/spack-matrix.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/spack-matrix.yml b/.github/workflows/spack-matrix.yml index 6810c6c7..455e4e2a 100644 --- a/.github/workflows/spack-matrix.yml +++ b/.github/workflows/spack-matrix.yml @@ -2,8 +2,8 @@ name: 🤖 on: push: - branches: - - main + # branches: + # - main pull_request: workflow_dispatch: schedule: From b830b24032982b148d89fb9481f8243798110510 Mon Sep 17 00:00:00 2001 From: schnellerhase <56360279+schnellerhase@users.noreply.github.com> Date: Fri, 5 Dec 2025 21:51:49 +0100 Subject: [PATCH 3/5] build-essential --- .github/actions/test-package/action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/actions/test-package/action.yml b/.github/actions/test-package/action.yml index 51ceb996..732f608e 100644 --- a/.github/actions/test-package/action.yml +++ b/.github/actions/test-package/action.yml @@ -17,7 +17,7 @@ runs: shell: sh run: | apt-get -y update - apt-get install -y bzip2 curl file git gzip make patch tar unzip xz-utils + apt-get install -y bzip2 curl file git gzip make patch tar unzip xz-utils build-essential - uses: actions/setup-python@v6 with: From 55a833be4ff0eee0463f5c226aee86e94aa79ce9 Mon Sep 17 00:00:00 2001 From: schnellerhase <56360279+schnellerhase@users.noreply.github.com> Date: Sat, 24 Jan 2026 23:29:43 +0100 Subject: [PATCH 4/5] only basix --- .github/workflows/spack-matrix.yml | 328 ++++++++++++++--------------- 1 file changed, 164 insertions(+), 164 deletions(-) diff --git a/.github/workflows/spack-matrix.yml b/.github/workflows/spack-matrix.yml index 455e4e2a..becbf71a 100644 --- a/.github/workflows/spack-matrix.yml +++ b/.github/workflows/spack-matrix.yml @@ -50,172 +50,172 @@ jobs: with: spec: fenics-basix@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} - fenics-dolfinx: - needs: style-check - runs-on: ubuntu-latest - container: ubuntu:24.04 - strategy: - fail-fast: false - matrix: - version: ["main", "0.10", "0.9", "0.8"] - variant: ["build_type=Developer", "partitioners=kahip,parmetis,scotch", "+petsc +slepc +adios2"] - compiler: ["gcc@13", "clang@18"] - exclude: - # kahip does not support clang - - variant: "partitioners=kahip,parmetis,scotch" - compiler: "clang@18" - steps: - - uses: actions/checkout@v5 - with: - path: spack-fenics - - uses: ./spack-fenics/.github/actions/test-package - with: - spec: fenics-dolfinx@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} + # fenics-dolfinx: + # needs: style-check + # runs-on: ubuntu-latest + # container: ubuntu:24.04 + # strategy: + # fail-fast: false + # matrix: + # version: ["main", "0.10", "0.9", "0.8"] + # variant: ["build_type=Developer", "partitioners=kahip,parmetis,scotch", "+petsc +slepc +adios2"] + # compiler: ["gcc@13", "clang@18"] + # exclude: + # # kahip does not support clang + # - variant: "partitioners=kahip,parmetis,scotch" + # compiler: "clang@18" + # steps: + # - uses: actions/checkout@v5 + # with: + # path: spack-fenics + # - uses: ./spack-fenics/.github/actions/test-package + # with: + # spec: fenics-dolfinx@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} - fenics-ufcx: - needs: style-check - runs-on: ubuntu-latest - container: ubuntu:24.04 - strategy: - fail-fast: false - matrix: - version: ["main", "0.10", "0.9", "0.8"] - compiler: ["gcc@13", "clang@18"] - steps: - - uses: actions/checkout@v5 - with: - path: spack-fenics - - uses: ./spack-fenics/.github/actions/test-package - with: - spec: fenics-ufcx@${{ matrix.version }} %${{ matrix.compiler }} + # fenics-ufcx: + # needs: style-check + # runs-on: ubuntu-latest + # container: ubuntu:24.04 + # strategy: + # fail-fast: false + # matrix: + # version: ["main", "0.10", "0.9", "0.8"] + # compiler: ["gcc@13", "clang@18"] + # steps: + # - uses: actions/checkout@v5 + # with: + # path: spack-fenics + # - uses: ./spack-fenics/.github/actions/test-package + # with: + # spec: fenics-ufcx@${{ matrix.version }} %${{ matrix.compiler }} - py-fenics-basix: - needs: style-check - runs-on: ubuntu-latest - container: ubuntu:24.04 - strategy: - fail-fast: false - matrix: - version: ["main", "0.10", "0.9", "0.8"] - variant: ["", "+ufl"] - compiler: ["gcc@13", "clang@18"] - steps: - - uses: actions/checkout@v5 - with: - path: spack-fenics - - uses: ./spack-fenics/.github/actions/test-package - with: - spec: py-fenics-basix@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} - # workaround for https://github.com/spack/spack/issues/29447 - - name: Run tests (> 0.8) - if: ${{ matrix.version != '0.8' && contains(matrix.variant, '+ufl') }} - shell: spack-bash {0} - run: | - spack env activate ./env - spack install --add py-pytest py-sympy - spack stage py-fenics-basix@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} - spack cd py-fenics-basix@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} - pytest test/ - # 0.8 holds one broken test case - - name: Run tests (0.8) - if: ${{ matrix.version == '0.8' && contains(matrix.variant, '+ufl') }} - shell: spack-bash {0} - run: | - spack env activate ./env - spack install --add py-pytest py-sympy - spack stage py-fenics-basix@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} - spack cd py-fenics-basix@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} - pytest test/ -k "not test_all_elements_included" + # py-fenics-basix: + # needs: style-check + # runs-on: ubuntu-latest + # container: ubuntu:24.04 + # strategy: + # fail-fast: false + # matrix: + # version: ["main", "0.10", "0.9", "0.8"] + # variant: ["", "+ufl"] + # compiler: ["gcc@13", "clang@18"] + # steps: + # - uses: actions/checkout@v5 + # with: + # path: spack-fenics + # - uses: ./spack-fenics/.github/actions/test-package + # with: + # spec: py-fenics-basix@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} + # # workaround for https://github.com/spack/spack/issues/29447 + # - name: Run tests (> 0.8) + # if: ${{ matrix.version != '0.8' && contains(matrix.variant, '+ufl') }} + # shell: spack-bash {0} + # run: | + # spack env activate ./env + # spack install --add py-pytest py-sympy + # spack stage py-fenics-basix@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} + # spack cd py-fenics-basix@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} + # pytest test/ + # # 0.8 holds one broken test case + # - name: Run tests (0.8) + # if: ${{ matrix.version == '0.8' && contains(matrix.variant, '+ufl') }} + # shell: spack-bash {0} + # run: | + # spack env activate ./env + # spack install --add py-pytest py-sympy + # spack stage py-fenics-basix@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} + # spack cd py-fenics-basix@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} + # pytest test/ -k "not test_all_elements_included" - py-fenics-dolfinx: - needs: style-check - runs-on: ubuntu-latest - container: ubuntu:24.04 - strategy: - fail-fast: false - matrix: - version: ["main", "0.10", "0.9", "0.8"] - variant: ["build_type=Developer", "+petsc4py +slepc4py"] - compiler: ["gcc@13", "clang@18"] - python-version: ["3.10", "3.11", "3.12", "3.13"] - steps: - - uses: actions/checkout@v5 - with: - path: spack-fenics - - uses: ./spack-fenics/.github/actions/test-package - with: - spec: py-fenics-dolfinx@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} - python-version: ${{ matrix.python-version }} - # workaround for https://github.com/spack/spack/issues/29447 - # pytest@8.4 required for collision of [tool.pytest] and [tool.pytest.ini_options] since @9.0 (at least for dolfinx @:0.9) - - name: Run tests - if: ${{ matrix.version == '0.8' || matrix.version == '0.9'}} - shell: spack-bash {0} - run: | - spack env activate ./env - spack install --add py-pytest@8.4 py-scipy - spack stage py-fenics-dolfinx@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} - spack cd py-fenics-dolfinx@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} - pytest python/test/unit -m "not petsc4py and not adios2" -k "not test_cffi_expression and not test_cube_distance" - - name: Run tests - if: ${{ matrix.version != '0.8' && matrix.version != '0.9'}} - shell: spack-bash {0} - run: | - spack env activate ./env - spack install --add py-pytest@8.4 py-scipy - spack stage py-fenics-dolfinx@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} - spack cd py-fenics-dolfinx@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} - pytest python/test/unit -m "not petsc4py and not adios2" -k "not test_cffi_expression" + # py-fenics-dolfinx: + # needs: style-check + # runs-on: ubuntu-latest + # container: ubuntu:24.04 + # strategy: + # fail-fast: false + # matrix: + # version: ["main", "0.10", "0.9", "0.8"] + # variant: ["build_type=Developer", "+petsc4py +slepc4py"] + # compiler: ["gcc@13", "clang@18"] + # python-version: ["3.10", "3.11", "3.12", "3.13"] + # steps: + # - uses: actions/checkout@v5 + # with: + # path: spack-fenics + # - uses: ./spack-fenics/.github/actions/test-package + # with: + # spec: py-fenics-dolfinx@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} + # python-version: ${{ matrix.python-version }} + # # workaround for https://github.com/spack/spack/issues/29447 + # # pytest@8.4 required for collision of [tool.pytest] and [tool.pytest.ini_options] since @9.0 (at least for dolfinx @:0.9) + # - name: Run tests + # if: ${{ matrix.version == '0.8' || matrix.version == '0.9'}} + # shell: spack-bash {0} + # run: | + # spack env activate ./env + # spack install --add py-pytest@8.4 py-scipy + # spack stage py-fenics-dolfinx@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} + # spack cd py-fenics-dolfinx@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} + # pytest python/test/unit -m "not petsc4py and not adios2" -k "not test_cffi_expression and not test_cube_distance" + # - name: Run tests + # if: ${{ matrix.version != '0.8' && matrix.version != '0.9'}} + # shell: spack-bash {0} + # run: | + # spack env activate ./env + # spack install --add py-pytest@8.4 py-scipy + # spack stage py-fenics-dolfinx@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} + # spack cd py-fenics-dolfinx@${{ matrix.version }} ${{ matrix.variant }} %${{ matrix.compiler }} + # pytest python/test/unit -m "not petsc4py and not adios2" -k "not test_cffi_expression" - py-fenics-ffcx: - needs: style-check - runs-on: ubuntu-latest - container: ubuntu:24.04 - strategy: - fail-fast: false - matrix: - version: ["main", "0.10", "0.9", "0.8"] - steps: - - uses: actions/checkout@v5 - with: - path: spack-fenics - - uses: ./spack-fenics/.github/actions/test-package - with: - spec: py-fenics-ffcx@${{ matrix.version }} - # workaround for https://github.com/spack/spack/issues/29447 - # we do not run numba based tests here due to disk-space constraints - # 0.8 broken - - name: Run tests - if: ${{ matrix.version != '0.8' }} - shell: spack-bash {0} - run: | - spack env activate ./env - spack install --add py-pytest py-sympy - spack stage py-fenics-ffcx@${{ matrix.version }} - spack cd py-fenics-ffcx@${{ matrix.version }} - pytest test/ + # py-fenics-ffcx: + # needs: style-check + # runs-on: ubuntu-latest + # container: ubuntu:24.04 + # strategy: + # fail-fast: false + # matrix: + # version: ["main", "0.10", "0.9", "0.8"] + # steps: + # - uses: actions/checkout@v5 + # with: + # path: spack-fenics + # - uses: ./spack-fenics/.github/actions/test-package + # with: + # spec: py-fenics-ffcx@${{ matrix.version }} + # # workaround for https://github.com/spack/spack/issues/29447 + # # we do not run numba based tests here due to disk-space constraints + # # 0.8 broken + # - name: Run tests + # if: ${{ matrix.version != '0.8' }} + # shell: spack-bash {0} + # run: | + # spack env activate ./env + # spack install --add py-pytest py-sympy + # spack stage py-fenics-ffcx@${{ matrix.version }} + # spack cd py-fenics-ffcx@${{ matrix.version }} + # pytest test/ - py-fenics-ufl: - needs: style-check - runs-on: ubuntu-latest - container: ubuntu:24.04 - strategy: - fail-fast: false - matrix: - version: ["main", "2025.2", "2025.1", "2024.2", "2024.1"] - steps: - - uses: actions/checkout@v5 - with: - path: spack-fenics - - uses: ./spack-fenics/.github/actions/test-package - with: - spec: py-fenics-ufl@${{ matrix.version }} - # workaround for https://github.com/spack/spack/issues/29447 - - name: Run tests - shell: spack-bash {0} - run: | - spack env activate ./env - spack install --add py-pytest - spack stage py-fenics-ufl@${{ matrix.version }} - spack cd py-fenics-ufl@${{ matrix.version }} - pytest test/ + # py-fenics-ufl: + # needs: style-check + # runs-on: ubuntu-latest + # container: ubuntu:24.04 + # strategy: + # fail-fast: false + # matrix: + # version: ["main", "2025.2", "2025.1", "2024.2", "2024.1"] + # steps: + # - uses: actions/checkout@v5 + # with: + # path: spack-fenics + # - uses: ./spack-fenics/.github/actions/test-package + # with: + # spec: py-fenics-ufl@${{ matrix.version }} + # # workaround for https://github.com/spack/spack/issues/29447 + # - name: Run tests + # shell: spack-bash {0} + # run: | + # spack env activate ./env + # spack install --add py-pytest + # spack stage py-fenics-ufl@${{ matrix.version }} + # spack cd py-fenics-ufl@${{ matrix.version }} + # pytest test/ From f5298c4db801b59cf529f511b80a74e5bd727e54 Mon Sep 17 00:00:00 2001 From: schnellerhase <56360279+schnellerhase@users.noreply.github.com> Date: Sat, 24 Jan 2026 23:30:46 +0100 Subject: [PATCH 5/5] revert on push --- .github/workflows/spack-matrix.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/spack-matrix.yml b/.github/workflows/spack-matrix.yml index becbf71a..600308fb 100644 --- a/.github/workflows/spack-matrix.yml +++ b/.github/workflows/spack-matrix.yml @@ -2,8 +2,8 @@ name: 🤖 on: push: - # branches: - # - main + branches: + - main pull_request: workflow_dispatch: schedule: