From df92778363fe695198b74796b649d9864170120b Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Mon, 30 Mar 2026 17:00:46 +0200 Subject: [PATCH 01/17] Improvement: Add Mac OS CI workflow --- .github/workflows/test_t8code_macos.yml | 168 ++++++++++++++++++++++++ .github/workflows/testsuite.yml | 23 ++++ 2 files changed, 191 insertions(+) create mode 100644 .github/workflows/test_t8code_macos.yml diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml new file mode 100644 index 0000000000..9ddcdd585d --- /dev/null +++ b/.github/workflows/test_t8code_macos.yml @@ -0,0 +1,168 @@ +name: CMake tests t8code on Mac OS + + +# This file is part of t8code. +# t8code is a C library to manage a collection (a forest) of multiple +# connected adaptive space-trees of general element types in parallel. +# +# Copyright (C) 2026 the developers +# +# t8code is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# t8code is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with t8code; if not, write to the Free Software Foundation, Inc., +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + +# This workflow checks whether building and testing works on Mac OS. +# In the past, this meant that Mac-OS-specific problems in t8code became +# apparrent only in Trixi and T8Code.jl, where they are very hard and +# cumbersome to debug. This workflow is intended to avoid that by catching +# such problems as early as possible, i.e., within t8code's CI. +# not just all of t8code's remaining CI workflows rely +# To reduce runtime, (for now) only one configuration is run, that is, Debug mode +# with MPI and all external libraries (VTK, OpenCASCADE). + +env: + DEBUG_CONFIG: "-O1" + +on: + workflow_call: + # Note: To simplify adding more configurations of this workflow later, the MPI mode and the BUILD_TYPE + # are passed as input, although currently only MPI on and Debug mode are tested. + inputs: + MAKEFLAGS: + required: true + type: string + description: 'Make flags to use for compilation (like -j4)' + MPI: + required: true + type: string + description: 'Use MPI for compilation (ON/OFF)' + BUILD_TYPE: + required: true + type: string + description: 'Build type (Release/Debug)' + TEST_LEVEL: + required: true + type: string + description: 'Test level used for configuring (T8_TEST_LEVEL_FULL, T8_TEST_LEVEL_MEDIUM, or T8_TEST_LEVEL_BASIC)' + default: 'T8_TEST_LEVEL_FULL' + +jobs: + t8code_cmake_tests: + # + # Container setup: To avoid unwanted side effects of gcc or mpich, an own Clang version of the + # t8-dependencies Docker image is used. Aside from some basic packages, it contains a manually built + # Clang version of OpenMPI. + timeout-minutes: 60 + runs-on: macos-latest + steps: + # + # Part 1: Preparation and sanity checks + # ------------------------------------- + - uses: actions/checkout@v6 + with: + fetch-depth: 0 + - name: First dummy command + run: echo "Hello from Mac OS!" + # - name: Update packages + # run: apt-get update && apt-get upgrade -y + - name: Show Clang version + run: clang --version + # - name: Make sure MPI was built with CLANG + # # Note: If "clang" is not found (or "gcc" is), the workflow is exited due to fail-early mode + # run: | + # mpicc --version > mpi_version_output + # cat mpi_version_output + # grep -i "clang" mpi_version_output + # ! grep -i "gcc" mpi_version_output + # rm mpi_version_output + # echo "CHECKED: MPI was built with Clang." + # - name: Assert correct MPI paths + # run: | + # mpicc --showme:compile | grep "${OMPI_INSTALL_PATH}" + # mpicc --showme:link | grep "${OMPI_INSTALL_PATH}" + # mpicxx --showme:compile | grep "${OMPI_INSTALL_PATH}" + # mpicxx --showme:link | grep "${OMPI_INSTALL_PATH}" + # echo "CHECKED: mpicc and mpicxx point to correct path" + # # This seems to be necessary because of the docker container + # - name: disable ownership checks + # run: git config --global --add safe.directory '*' + # - name: init submodules + # run: git submodule init + # - name: update submodules + # run: git submodule update + # - name: Get input vars + # run: export MAKEFLAGS="${{ inputs.MAKEFLAGS }}" + # && export MPI="${{ inputs.MPI }}" + # && export BUILD_TYPE="${{ inputs.BUILD_TYPE }}" + # && echo MAKEFLAGS="$MAKEFLAGS" >> $GITHUB_ENV + # && echo MPI="$MPI" >> $GITHUB_ENV + # && echo BUILD_TYPE="$BUILD_TYPE" >> $GITHUB_ENV + # # + # # Part 2: Build t8code + # # -------------------- + # # Define build config + # - name: Set test level + # run: export TEST_LEVEL_FLAG="-DT8CODE_TEST_LEVEL=${{ inputs.TEST_LEVEL }}" + # && echo TEST_LEVEL_FLAG="$TEST_LEVEL_FLAG" >> $GITHUB_ENV + # - name: build config variables + # run: | + # export CONFIG_OPTIONS="-DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -DCMAKE_Fortran_COMPILER=mpifort -GNinja \ + # -DT8CODE_ENABLE_MPI=$MPI -DCMAKE_BUILD_TYPE=$BUILD_TYPE ${TEST_LEVEL_FLAG} -DCMAKE_C_FLAGS_DEBUG=${DEBUG_CONFIG} -DCMAKE_CXX_FLAGS_DEBUG=${DEBUG_CONFIG} \ + # -DT8CODE_BUILD_PEDANTIC=ON -DT8CODE_BUILD_WALL=ON -DT8CODE_BUILD_WERROR=ON -DT8CODE_BUILD_WEXTRA=ON \ + # -DT8CODE_BUILD_FORTRAN_INTERFACE=ON -DT8CODE_BUILD_MESH_HANDLE=ON \ + # -DT8CODE_ENABLE_OCC=ON -DT8CODE_ENABLE_VTK=ON -DVTK_DIR=$VTK_INSTALL_PATH/lib/cmake/vtk-9.1" + # echo CONFIG_OPTIONS="$CONFIG_OPTIONS" >> $GITHUB_ENV + # # Run cmake + # - name: echo cmake line + # run: echo cmake ../ $CONFIG_OPTIONS + # - name: cmake + # run: mkdir build && cd build && cmake ../ $CONFIG_OPTIONS + # # On failure, upload logs + # - name: OnFailUploadLog + # if: failure() + # uses: actions/upload-artifact@v7 + # with: + # name: cmake_w_clang_and_ompi_${{ inputs.BUILD_TYPE }}_MPI_${{ inputs.MPI }}.log + # path: build/CMakeFiles/CMakeOutput.log + # # Build with ninja + # - name: ninja + # run: cd build && ninja $MAKEFLAGS + # - name: ninja install + # run: cd build && ninja install $MAKEFLAGS + # # + # # Part 3: Run t8code tests + # # ------------------------ + # - name: serial tests (if MPI is enabled) + # run: cd build && ctest $MAKEFLAGS -R _serial + # if: ${{ inputs.MPI == 'ON' }} + # - name: parallel tests (if MPI is enabled) + # run: cd build && ctest -R _parallel + # env: + # # Note: These openmpi options are required to ensure stable runs in github workflows and avoid stalling. + # # In particular, they activate oversubscription and define the communication channels, here tcp (and self). + # OMPI_ALLOW_RUN_AS_ROOT: 1 + # OMPI_ALLOW_RUN_AS_ROOT_CONFIRM: 1 + # OMPI_MCA_rmaps_base_oversubscribe: 1 + # OMPI_MCA_btl: self,tcp + # OMPI_MCA_pml: ob1 + # if: ${{ inputs.MPI == 'ON' }} + # - name: tests (if MPI is disabled) + # run: cd build && ctest $MAKEFLAGS + # if: ${{ inputs.MPI == 'OFF' }} + # # On failure, upload logs + # - name: OnFailUploadLog + # if: failure() + # uses: actions/upload-artifact@v7 + # with: + # name: test-suite_w_clang_and_ompi_${{ inputs.BUILD_TYPE }}_MPI_${{ inputs.MPI }}.log + # path: build/Testing/Temporary/LastTest.log diff --git a/.github/workflows/testsuite.yml b/.github/workflows/testsuite.yml index 631f7f48e8..b29908a481 100644 --- a/.github/workflows/testsuite.yml +++ b/.github/workflows/testsuite.yml @@ -242,6 +242,29 @@ jobs: BUILD_TYPE: ${{ matrix.BUILD_TYPE }} TEST_LEVEL: ${{ github.event_name == 'pull_request' && 'T8_TEST_LEVEL_MEDIUM' || 'T8_TEST_LEVEL_FULL' }} # Set TEST_LEVEL to medium if the event is a PR, otherwise full. + # Check t8code building and testing with the Clang compiler and openmpi. + # Note: This workflow is meant to detect Clang- or openmpi-specific issues missed by the remaining (gcc- and mpich-based) workflows. + # To reduce its runtime, it currently only uses one run in Debug mode with MPI activated and all external libraries like VTK or OpenCASCADE. + t8code_macos_tests: + needs: fine_grained_trigger + secrets: inherit + if: ${{ needs.fine_grained_trigger.outputs.run_ci == 'true' }} + uses: ./.github/workflows/test_t8code_macos.yml + strategy: + fail-fast: false + matrix: + MPI: [ON] + BUILD_TYPE: [Debug] + include: + - MAKEFLAGS: -j4 + with: + MAKEFLAGS: ${{ matrix.MAKEFLAGS }} + MPI: ${{ matrix.MPI }} + BUILD_TYPE: ${{ matrix.BUILD_TYPE }} + TEST_LEVEL: ${{ github.event_name == 'pull_request' && 'T8_TEST_LEVEL_MEDIUM' || 'T8_TEST_LEVEL_FULL' }} # Set TEST_LEVEL to medium if the event is a PR, otherwise full. + + + # Build doxygen documentation and check for errors / warnings. t8code_doxygen_check: uses: ./.github/workflows/check_doxygen.yml From 3346b8492b409e5a27682dc57f1e88f75501e93e Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Mon, 30 Mar 2026 17:03:06 +0200 Subject: [PATCH 02/17] First tests [run ci] --- .github/workflows/test_t8code_macos.yml | 12 +- .github/workflows/testsuite.yml | 238 ++++++++++++------------ 2 files changed, 125 insertions(+), 125 deletions(-) diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml index 9ddcdd585d..1552adef92 100644 --- a/.github/workflows/test_t8code_macos.yml +++ b/.github/workflows/test_t8code_macos.yml @@ -94,12 +94,12 @@ jobs: # mpicxx --showme:link | grep "${OMPI_INSTALL_PATH}" # echo "CHECKED: mpicc and mpicxx point to correct path" # # This seems to be necessary because of the docker container - # - name: disable ownership checks - # run: git config --global --add safe.directory '*' - # - name: init submodules - # run: git submodule init - # - name: update submodules - # run: git submodule update + - name: disable ownership checks + run: git config --global --add safe.directory '*' + - name: init submodules + run: git submodule init + - name: update submodules + run: git submodule update # - name: Get input vars # run: export MAKEFLAGS="${{ inputs.MAKEFLAGS }}" # && export MPI="${{ inputs.MPI }}" diff --git a/.github/workflows/testsuite.yml b/.github/workflows/testsuite.yml index b29908a481..507ce524b1 100644 --- a/.github/workflows/testsuite.yml +++ b/.github/workflows/testsuite.yml @@ -123,124 +123,124 @@ jobs: CACHE_COUNTER: 0 # Increase this number to force a new installation of sc and p4est and to update the cache once MPI: ${{ matrix.MPI }} - # Run parallel tests for sc and p4est with and without MPI - sc_p4est_tests: - needs: preparation - uses: ./.github/workflows/test_sc_p4est.yml - strategy: - fail-fast: false - matrix: - MPI: [OFF, ON] - include: - - MAKEFLAGS: -j4 - with: - MAKEFLAGS: ${{ matrix.MAKEFLAGS }} - MPI: ${{ matrix.MPI }} + # # Run parallel tests for sc and p4est with and without MPI + # sc_p4est_tests: + # needs: preparation + # uses: ./.github/workflows/test_sc_p4est.yml + # strategy: + # fail-fast: false + # matrix: + # MPI: [OFF, ON] + # include: + # - MAKEFLAGS: -j4 + # with: + # MAKEFLAGS: ${{ matrix.MAKEFLAGS }} + # MPI: ${{ matrix.MPI }} - # Run t8code tests with and without MPI and in serial and debug mode - t8code_tests: - needs: preparation - uses: ./.github/workflows/test_t8code.yml - strategy: - fail-fast: false - matrix: - MPI: [OFF, ON] - BUILD_TYPE: [Debug, Release] - include: - - MAKEFLAGS: -j4 - with: - MAKEFLAGS: ${{ matrix.MAKEFLAGS }} - MPI: ${{ matrix.MPI }} - BUILD_TYPE: ${{ matrix.BUILD_TYPE }} - TEST_LEVEL: ${{ github.event_name == 'pull_request' && 'T8_TEST_LEVEL_MEDIUM' || 'T8_TEST_LEVEL_FULL' }} # Set TEST_LEVEL to medium if the event is a PR, otherwise full. + # # Run t8code tests with and without MPI and in serial and debug mode + # t8code_tests: + # needs: preparation + # uses: ./.github/workflows/test_t8code.yml + # strategy: + # fail-fast: false + # matrix: + # MPI: [OFF, ON] + # BUILD_TYPE: [Debug, Release] + # include: + # - MAKEFLAGS: -j4 + # with: + # MAKEFLAGS: ${{ matrix.MAKEFLAGS }} + # MPI: ${{ matrix.MPI }} + # BUILD_TYPE: ${{ matrix.BUILD_TYPE }} + # TEST_LEVEL: ${{ github.event_name == 'pull_request' && 'T8_TEST_LEVEL_MEDIUM' || 'T8_TEST_LEVEL_FULL' }} # Set TEST_LEVEL to medium if the event is a PR, otherwise full. - # Run t8code linkage tests with and without MPI and in serial and debug mode - t8code_linkage_tests: - needs: preparation - uses: ./.github/workflows/test_t8code_linkage.yml - strategy: - fail-fast: false - matrix: - MPI: [OFF, ON] - BUILD_TYPE: [Debug, Release] - include: - - MAKEFLAGS: -j4 - with: - MAKEFLAGS: ${{ matrix.MAKEFLAGS }} - MPI: ${{ matrix.MPI }} - BUILD_TYPE: ${{ matrix.BUILD_TYPE }} - TEST_LEVEL: ${{ github.event_name == 'pull_request' && 'T8_TEST_LEVEL_MEDIUM' || 'T8_TEST_LEVEL_FULL' }} # Set TEST_LEVEL to medium if the event is a PR, otherwise full. + # # Run t8code linkage tests with and without MPI and in serial and debug mode + # t8code_linkage_tests: + # needs: preparation + # uses: ./.github/workflows/test_t8code_linkage.yml + # strategy: + # fail-fast: false + # matrix: + # MPI: [OFF, ON] + # BUILD_TYPE: [Debug, Release] + # include: + # - MAKEFLAGS: -j4 + # with: + # MAKEFLAGS: ${{ matrix.MAKEFLAGS }} + # MPI: ${{ matrix.MPI }} + # BUILD_TYPE: ${{ matrix.BUILD_TYPE }} + # TEST_LEVEL: ${{ github.event_name == 'pull_request' && 'T8_TEST_LEVEL_MEDIUM' || 'T8_TEST_LEVEL_FULL' }} # Set TEST_LEVEL to medium if the event is a PR, otherwise full. - # Run t8code linkage tests with and without MPI and in serial and debug mode - t8code_api_tests: - needs: preparation - uses: ./.github/workflows/test_t8code_api.yml - strategy: - fail-fast: false - matrix: - MPI: [ON] # For now the fortran API only supports building with MPI - BUILD_TYPE: [Debug, Release] - include: - - MAKEFLAGS: -j4 - with: - MAKEFLAGS: ${{ matrix.MAKEFLAGS }} - MPI: ${{ matrix.MPI }} - BUILD_TYPE: ${{ matrix.BUILD_TYPE }} - TEST_LEVEL: ${{ github.event_name == 'pull_request' && 'T8_TEST_LEVEL_MEDIUM' || 'T8_TEST_LEVEL_FULL' }} # Set TEST_LEVEL to medium if the event is a PR, otherwise full. + # # Run t8code linkage tests with and without MPI and in serial and debug mode + # t8code_api_tests: + # needs: preparation + # uses: ./.github/workflows/test_t8code_api.yml + # strategy: + # fail-fast: false + # matrix: + # MPI: [ON] # For now the fortran API only supports building with MPI + # BUILD_TYPE: [Debug, Release] + # include: + # - MAKEFLAGS: -j4 + # with: + # MAKEFLAGS: ${{ matrix.MAKEFLAGS }} + # MPI: ${{ matrix.MPI }} + # BUILD_TYPE: ${{ matrix.BUILD_TYPE }} + # TEST_LEVEL: ${{ github.event_name == 'pull_request' && 'T8_TEST_LEVEL_MEDIUM' || 'T8_TEST_LEVEL_FULL' }} # Set TEST_LEVEL to medium if the event is a PR, otherwise full. - # Run Valgrind check for every t8code test binary. - t8code_valgrind_tests: - if: (github.event_name == 'schedule' && github.repository == 'DLR-AMR/t8code') # Only run the Valgrind check in the scheduled run. - needs: preparation - uses: ./.github/workflows/test_valgrind.yml - with: - TEST_LEVEL: T8_TEST_LEVEL_BASIC # Do Valgrind check for test level T8_TEST_LEVEL_BASIC for performance reasons. + # # Run Valgrind check for every t8code test binary. + # t8code_valgrind_tests: + # if: (github.event_name == 'schedule' && github.repository == 'DLR-AMR/t8code') # Only run the Valgrind check in the scheduled run. + # needs: preparation + # uses: ./.github/workflows/test_valgrind.yml + # with: + # TEST_LEVEL: T8_TEST_LEVEL_BASIC # Do Valgrind check for test level T8_TEST_LEVEL_BASIC for performance reasons. - # Generate code coverage and deploy to Codecov. - t8code_code_coverage: - if: (github.event_name != 'merge_group') - needs: preparation - uses: ./.github/workflows/code_coverage.yml - with: - MAKEFLAGS: -j4 - MPI: ON - BUILD_TYPE: Debug - TEST_LEVEL: T8_TEST_LEVEL_BASIC - secrets: - CODE_COV: ${{ secrets.CODE_COV }} + # # Generate code coverage and deploy to Codecov. + # t8code_code_coverage: + # if: (github.event_name != 'merge_group') + # needs: preparation + # uses: ./.github/workflows/code_coverage.yml + # with: + # MAKEFLAGS: -j4 + # MPI: ON + # BUILD_TYPE: Debug + # TEST_LEVEL: T8_TEST_LEVEL_BASIC + # secrets: + # CODE_COV: ${{ secrets.CODE_COV }} - # Run t8code tests with shipped submodules. This test is only for the build system, so only one config is tested. - t8code_w_shipped_submodules_tests: - needs: fine_grained_trigger - secrets: inherit - if: ${{ needs.fine_grained_trigger.outputs.run_ci == 'true' }} - uses: ./.github/workflows/test_t8code_w_shipped_submodules.yml - with: - MAKEFLAGS: -j4 - MPI: ON - BUILD_TYPE: Debug - TEST_LEVEL: ${{ github.event_name == 'pull_request' && 'T8_TEST_LEVEL_MEDIUM' || 'T8_TEST_LEVEL_FULL' }} # Set TEST_LEVEL to medium if the event is a PR, otherwise full. + # # Run t8code tests with shipped submodules. This test is only for the build system, so only one config is tested. + # t8code_w_shipped_submodules_tests: + # needs: fine_grained_trigger + # secrets: inherit + # if: ${{ needs.fine_grained_trigger.outputs.run_ci == 'true' }} + # uses: ./.github/workflows/test_t8code_w_shipped_submodules.yml + # with: + # MAKEFLAGS: -j4 + # MPI: ON + # BUILD_TYPE: Debug + # TEST_LEVEL: ${{ github.event_name == 'pull_request' && 'T8_TEST_LEVEL_MEDIUM' || 'T8_TEST_LEVEL_FULL' }} # Set TEST_LEVEL to medium if the event is a PR, otherwise full. - # Check t8code building and testing with the Clang compiler and openmpi. - # Note: This workflow is meant to detect Clang- or openmpi-specific issues missed by the remaining (gcc- and mpich-based) workflows. - # To reduce its runtime, it currently only uses one run in Debug mode with MPI activated and all external libraries like VTK or OpenCASCADE. - t8code_w_clang_and_ompi_tests: - needs: fine_grained_trigger - secrets: inherit - if: ${{ needs.fine_grained_trigger.outputs.run_ci == 'true' }} - uses: ./.github/workflows/test_t8code_w_clang_and_ompi.yml - strategy: - fail-fast: false - matrix: - MPI: [ON] - BUILD_TYPE: [Debug] - include: - - MAKEFLAGS: -j4 - with: - MAKEFLAGS: ${{ matrix.MAKEFLAGS }} - MPI: ${{ matrix.MPI }} - BUILD_TYPE: ${{ matrix.BUILD_TYPE }} - TEST_LEVEL: ${{ github.event_name == 'pull_request' && 'T8_TEST_LEVEL_MEDIUM' || 'T8_TEST_LEVEL_FULL' }} # Set TEST_LEVEL to medium if the event is a PR, otherwise full. + # # Check t8code building and testing with the Clang compiler and openmpi. + # # Note: This workflow is meant to detect Clang- or openmpi-specific issues missed by the remaining (gcc- and mpich-based) workflows. + # # To reduce its runtime, it currently only uses one run in Debug mode with MPI activated and all external libraries like VTK or OpenCASCADE. + # t8code_w_clang_and_ompi_tests: + # needs: fine_grained_trigger + # secrets: inherit + # if: ${{ needs.fine_grained_trigger.outputs.run_ci == 'true' }} + # uses: ./.github/workflows/test_t8code_w_clang_and_ompi.yml + # strategy: + # fail-fast: false + # matrix: + # MPI: [ON] + # BUILD_TYPE: [Debug] + # include: + # - MAKEFLAGS: -j4 + # with: + # MAKEFLAGS: ${{ matrix.MAKEFLAGS }} + # MPI: ${{ matrix.MPI }} + # BUILD_TYPE: ${{ matrix.BUILD_TYPE }} + # TEST_LEVEL: ${{ github.event_name == 'pull_request' && 'T8_TEST_LEVEL_MEDIUM' || 'T8_TEST_LEVEL_FULL' }} # Set TEST_LEVEL to medium if the event is a PR, otherwise full. # Check t8code building and testing with the Clang compiler and openmpi. # Note: This workflow is meant to detect Clang- or openmpi-specific issues missed by the remaining (gcc- and mpich-based) workflows. @@ -265,12 +265,12 @@ jobs: - # Build doxygen documentation and check for errors / warnings. - t8code_doxygen_check: - uses: ./.github/workflows/check_doxygen.yml + # # Build doxygen documentation and check for errors / warnings. + # t8code_doxygen_check: + # uses: ./.github/workflows/check_doxygen.yml - t8code_tarball: - if: github.event.pull_request.draft == false - uses: ./.github/workflows/test_tarball.yml - with: - TEST_LEVEL: ${{ github.event_name == 'pull_request' && 'T8_TEST_LEVEL_MEDIUM' || 'T8_TEST_LEVEL_FULL' }} # Set TEST_LEVEL to medium if the event is a PR, otherwise full. + # t8code_tarball: + # if: github.event.pull_request.draft == false + # uses: ./.github/workflows/test_tarball.yml + # with: + # TEST_LEVEL: ${{ github.event_name == 'pull_request' && 'T8_TEST_LEVEL_MEDIUM' || 'T8_TEST_LEVEL_FULL' }} # Set TEST_LEVEL to medium if the event is a PR, otherwise full. From c35e5f7870cc3d892f0990bc3aae32f3b5f70c04 Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Mon, 30 Mar 2026 17:06:19 +0200 Subject: [PATCH 03/17] More tests [run ci] --- .github/workflows/test_t8code_macos.yml | 32 ++++++++++++------------- .github/workflows/testsuite.yml | 32 ++++++++++++------------- 2 files changed, 32 insertions(+), 32 deletions(-) diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml index 1552adef92..870e79cca1 100644 --- a/.github/workflows/test_t8code_macos.yml +++ b/.github/workflows/test_t8code_macos.yml @@ -71,12 +71,12 @@ jobs: - uses: actions/checkout@v6 with: fetch-depth: 0 - - name: First dummy command - run: echo "Hello from Mac OS!" # - name: Update packages # run: apt-get update && apt-get upgrade -y - name: Show Clang version run: clang --version + - name: Show mpicc version + run: mpicc --version # - name: Make sure MPI was built with CLANG # # Note: If "clang" is not found (or "gcc" is), the workflow is exited due to fail-early mode # run: | @@ -100,20 +100,20 @@ jobs: run: git submodule init - name: update submodules run: git submodule update - # - name: Get input vars - # run: export MAKEFLAGS="${{ inputs.MAKEFLAGS }}" - # && export MPI="${{ inputs.MPI }}" - # && export BUILD_TYPE="${{ inputs.BUILD_TYPE }}" - # && echo MAKEFLAGS="$MAKEFLAGS" >> $GITHUB_ENV - # && echo MPI="$MPI" >> $GITHUB_ENV - # && echo BUILD_TYPE="$BUILD_TYPE" >> $GITHUB_ENV - # # - # # Part 2: Build t8code - # # -------------------- - # # Define build config - # - name: Set test level - # run: export TEST_LEVEL_FLAG="-DT8CODE_TEST_LEVEL=${{ inputs.TEST_LEVEL }}" - # && echo TEST_LEVEL_FLAG="$TEST_LEVEL_FLAG" >> $GITHUB_ENV + - name: Get input vars + run: export MAKEFLAGS="${{ inputs.MAKEFLAGS }}" + && export MPI="${{ inputs.MPI }}" + && export BUILD_TYPE="${{ inputs.BUILD_TYPE }}" + && echo MAKEFLAGS="$MAKEFLAGS" >> $GITHUB_ENV + && echo MPI="$MPI" >> $GITHUB_ENV + && echo BUILD_TYPE="$BUILD_TYPE" >> $GITHUB_ENV + # + # Part 2: Build t8code + # -------------------- + # Define build config + - name: Set test level + run: export TEST_LEVEL_FLAG="-DT8CODE_TEST_LEVEL=${{ inputs.TEST_LEVEL }}" + && echo TEST_LEVEL_FLAG="$TEST_LEVEL_FLAG" >> $GITHUB_ENV # - name: build config variables # run: | # export CONFIG_OPTIONS="-DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -DCMAKE_Fortran_COMPILER=mpifort -GNinja \ diff --git a/.github/workflows/testsuite.yml b/.github/workflows/testsuite.yml index 507ce524b1..a054020008 100644 --- a/.github/workflows/testsuite.yml +++ b/.github/workflows/testsuite.yml @@ -106,22 +106,22 @@ jobs: fi # Preparation step for tests. Repo is cloned and sc + p4est are compiled with and without MPI. - preparation: - needs: [fine_grained_trigger] - secrets: inherit - if: needs.fine_grained_trigger.outputs.run_ci == 'true' - uses: ./.github/workflows/test_preparation.yml - strategy: - fail-fast: false - matrix: - MPI: [OFF, ON] - include: - - MAKEFLAGS: -j4 - with: - MAKEFLAGS: ${{ matrix.MAKEFLAGS }} - IGNORE_CACHE: false # Use this to force a new installation of sc and p4est for this specific workflow run - CACHE_COUNTER: 0 # Increase this number to force a new installation of sc and p4est and to update the cache once - MPI: ${{ matrix.MPI }} + # preparation: + # needs: [fine_grained_trigger] + # secrets: inherit + # if: needs.fine_grained_trigger.outputs.run_ci == 'true' + # uses: ./.github/workflows/test_preparation.yml + # strategy: + # fail-fast: false + # matrix: + # MPI: [OFF, ON] + # include: + # - MAKEFLAGS: -j4 + # with: + # MAKEFLAGS: ${{ matrix.MAKEFLAGS }} + # IGNORE_CACHE: false # Use this to force a new installation of sc and p4est for this specific workflow run + # CACHE_COUNTER: 0 # Increase this number to force a new installation of sc and p4est and to update the cache once + # MPI: ${{ matrix.MPI }} # # Run parallel tests for sc and p4est with and without MPI # sc_p4est_tests: From 9e2ab80edcf9df1f6bad6fbf00b4f60b124d8408 Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Mon, 30 Mar 2026 17:08:35 +0200 Subject: [PATCH 04/17] More tests [run ci] --- .github/workflows/test_t8code_macos.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml index 870e79cca1..af242f7140 100644 --- a/.github/workflows/test_t8code_macos.yml +++ b/.github/workflows/test_t8code_macos.yml @@ -75,6 +75,8 @@ jobs: # run: apt-get update && apt-get upgrade -y - name: Show Clang version run: clang --version + - name: Debug via SSH + uses: mxschmitt/action-tmate@v3 - name: Show mpicc version run: mpicc --version # - name: Make sure MPI was built with CLANG From 06804de2f71cff12edbb4ad555fa05a225a4f6f3 Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Mon, 30 Mar 2026 17:11:06 +0200 Subject: [PATCH 05/17] More tests [run ci] --- .github/workflows/test_t8code_macos.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml index af242f7140..aeda7009fc 100644 --- a/.github/workflows/test_t8code_macos.yml +++ b/.github/workflows/test_t8code_macos.yml @@ -71,8 +71,10 @@ jobs: - uses: actions/checkout@v6 with: fetch-depth: 0 - # - name: Update packages - # run: apt-get update && apt-get upgrade -y + - name: Update packages + run: brew update + - name: Install OpenMPI + run: brew install open-mpi - name: Show Clang version run: clang --version - name: Debug via SSH From bbe9221e5960bb8343bf8a59e2d2bbf6b1228d34 Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Mon, 30 Mar 2026 17:13:13 +0200 Subject: [PATCH 06/17] More tests [run ci] --- .github/workflows/test_t8code_macos.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml index aeda7009fc..f33b2dfecc 100644 --- a/.github/workflows/test_t8code_macos.yml +++ b/.github/workflows/test_t8code_macos.yml @@ -77,8 +77,6 @@ jobs: run: brew install open-mpi - name: Show Clang version run: clang --version - - name: Debug via SSH - uses: mxschmitt/action-tmate@v3 - name: Show mpicc version run: mpicc --version # - name: Make sure MPI was built with CLANG From 0ff629fa69c4f16c88ca1fa81bb511efabee0cf5 Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Mon, 30 Mar 2026 17:21:19 +0200 Subject: [PATCH 07/17] More tests [run ci] --- .github/workflows/test_t8code_macos.yml | 132 +++++++++++------------- 1 file changed, 58 insertions(+), 74 deletions(-) diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml index f33b2dfecc..94022c6d43 100644 --- a/.github/workflows/test_t8code_macos.yml +++ b/.github/workflows/test_t8code_macos.yml @@ -66,38 +66,22 @@ jobs: runs-on: macos-latest steps: # - # Part 1: Preparation and sanity checks + # Part 1: Preparation # ------------------------------------- - uses: actions/checkout@v6 with: fetch-depth: 0 - name: Update packages run: brew update - - name: Install OpenMPI - run: brew install open-mpi + - name: Install missing packages via Homebrew + run: brew install open-mpi ninja cmake - name: Show Clang version run: clang --version - name: Show mpicc version run: mpicc --version - # - name: Make sure MPI was built with CLANG - # # Note: If "clang" is not found (or "gcc" is), the workflow is exited due to fail-early mode - # run: | - # mpicc --version > mpi_version_output - # cat mpi_version_output - # grep -i "clang" mpi_version_output - # ! grep -i "gcc" mpi_version_output - # rm mpi_version_output - # echo "CHECKED: MPI was built with Clang." - # - name: Assert correct MPI paths - # run: | - # mpicc --showme:compile | grep "${OMPI_INSTALL_PATH}" - # mpicc --showme:link | grep "${OMPI_INSTALL_PATH}" - # mpicxx --showme:compile | grep "${OMPI_INSTALL_PATH}" - # mpicxx --showme:link | grep "${OMPI_INSTALL_PATH}" - # echo "CHECKED: mpicc and mpicxx point to correct path" - # # This seems to be necessary because of the docker container - - name: disable ownership checks - run: git config --global --add safe.directory '*' + + # - name: disable ownership checks + # run: git config --global --add safe.directory '*' - name: init submodules run: git submodule init - name: update submodules @@ -116,55 +100,55 @@ jobs: - name: Set test level run: export TEST_LEVEL_FLAG="-DT8CODE_TEST_LEVEL=${{ inputs.TEST_LEVEL }}" && echo TEST_LEVEL_FLAG="$TEST_LEVEL_FLAG" >> $GITHUB_ENV - # - name: build config variables - # run: | - # export CONFIG_OPTIONS="-DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -DCMAKE_Fortran_COMPILER=mpifort -GNinja \ - # -DT8CODE_ENABLE_MPI=$MPI -DCMAKE_BUILD_TYPE=$BUILD_TYPE ${TEST_LEVEL_FLAG} -DCMAKE_C_FLAGS_DEBUG=${DEBUG_CONFIG} -DCMAKE_CXX_FLAGS_DEBUG=${DEBUG_CONFIG} \ - # -DT8CODE_BUILD_PEDANTIC=ON -DT8CODE_BUILD_WALL=ON -DT8CODE_BUILD_WERROR=ON -DT8CODE_BUILD_WEXTRA=ON \ - # -DT8CODE_BUILD_FORTRAN_INTERFACE=ON -DT8CODE_BUILD_MESH_HANDLE=ON \ - # -DT8CODE_ENABLE_OCC=ON -DT8CODE_ENABLE_VTK=ON -DVTK_DIR=$VTK_INSTALL_PATH/lib/cmake/vtk-9.1" - # echo CONFIG_OPTIONS="$CONFIG_OPTIONS" >> $GITHUB_ENV - # # Run cmake - # - name: echo cmake line - # run: echo cmake ../ $CONFIG_OPTIONS - # - name: cmake - # run: mkdir build && cd build && cmake ../ $CONFIG_OPTIONS - # # On failure, upload logs - # - name: OnFailUploadLog - # if: failure() - # uses: actions/upload-artifact@v7 - # with: - # name: cmake_w_clang_and_ompi_${{ inputs.BUILD_TYPE }}_MPI_${{ inputs.MPI }}.log - # path: build/CMakeFiles/CMakeOutput.log - # # Build with ninja - # - name: ninja - # run: cd build && ninja $MAKEFLAGS - # - name: ninja install - # run: cd build && ninja install $MAKEFLAGS - # # - # # Part 3: Run t8code tests - # # ------------------------ - # - name: serial tests (if MPI is enabled) - # run: cd build && ctest $MAKEFLAGS -R _serial - # if: ${{ inputs.MPI == 'ON' }} - # - name: parallel tests (if MPI is enabled) - # run: cd build && ctest -R _parallel - # env: - # # Note: These openmpi options are required to ensure stable runs in github workflows and avoid stalling. - # # In particular, they activate oversubscription and define the communication channels, here tcp (and self). - # OMPI_ALLOW_RUN_AS_ROOT: 1 - # OMPI_ALLOW_RUN_AS_ROOT_CONFIRM: 1 - # OMPI_MCA_rmaps_base_oversubscribe: 1 - # OMPI_MCA_btl: self,tcp - # OMPI_MCA_pml: ob1 - # if: ${{ inputs.MPI == 'ON' }} - # - name: tests (if MPI is disabled) - # run: cd build && ctest $MAKEFLAGS - # if: ${{ inputs.MPI == 'OFF' }} - # # On failure, upload logs - # - name: OnFailUploadLog - # if: failure() - # uses: actions/upload-artifact@v7 - # with: - # name: test-suite_w_clang_and_ompi_${{ inputs.BUILD_TYPE }}_MPI_${{ inputs.MPI }}.log - # path: build/Testing/Temporary/LastTest.log + - name: build config variables + run: | + export CONFIG_OPTIONS="-DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -DCMAKE_Fortran_COMPILER=mpifort -GNinja \ + -DT8CODE_ENABLE_MPI=$MPI -DCMAKE_BUILD_TYPE=$BUILD_TYPE ${TEST_LEVEL_FLAG} -DCMAKE_C_FLAGS_DEBUG=${DEBUG_CONFIG} -DCMAKE_CXX_FLAGS_DEBUG=${DEBUG_CONFIG} \ + -DT8CODE_BUILD_PEDANTIC=ON -DT8CODE_BUILD_WALL=ON -DT8CODE_BUILD_WERROR=ON -DT8CODE_BUILD_WEXTRA=ON \ + -DT8CODE_BUILD_FORTRAN_INTERFACE=ON -DT8CODE_BUILD_MESH_HANDLE=ON \ + -DT8CODE_ENABLE_OCC=ON -DT8CODE_ENABLE_VTK=ON -DVTK_DIR=$VTK_INSTALL_PATH/lib/cmake/vtk-9.1" + echo CONFIG_OPTIONS="$CONFIG_OPTIONS" >> $GITHUB_ENV + # Run cmake + - name: echo cmake line + run: echo cmake ../ $CONFIG_OPTIONS + - name: cmake + run: mkdir build && cd build && cmake ../ $CONFIG_OPTIONS + # On failure, upload logs + - name: OnFailUploadLog + if: failure() + uses: actions/upload-artifact@v7 + with: + name: cmake_w_clang_and_ompi_${{ inputs.BUILD_TYPE }}_MPI_${{ inputs.MPI }}.log + path: build/CMakeFiles/CMakeOutput.log + # Build with ninja + - name: ninja + run: cd build && ninja $MAKEFLAGS + - name: ninja install + run: cd build && ninja install $MAKEFLAGS + # + # Part 3: Run t8code tests + # ------------------------ + - name: serial tests (if MPI is enabled) + run: cd build && ctest $MAKEFLAGS -R _serial + if: ${{ inputs.MPI == 'ON' }} + - name: parallel tests (if MPI is enabled) + run: cd build && ctest -R _parallel + env: + # Note: These openmpi options are required to ensure stable runs in github workflows and avoid stalling. + # In particular, they activate oversubscription and define the communication channels, here tcp (and self). + OMPI_ALLOW_RUN_AS_ROOT: 1 + OMPI_ALLOW_RUN_AS_ROOT_CONFIRM: 1 + OMPI_MCA_rmaps_base_oversubscribe: 1 + OMPI_MCA_btl: self,tcp + OMPI_MCA_pml: ob1 + if: ${{ inputs.MPI == 'ON' }} + - name: tests (if MPI is disabled) + run: cd build && ctest $MAKEFLAGS + if: ${{ inputs.MPI == 'OFF' }} + # On failure, upload logs + - name: OnFailUploadLog + if: failure() + uses: actions/upload-artifact@v7 + with: + name: test-suite_w_clang_and_ompi_${{ inputs.BUILD_TYPE }}_MPI_${{ inputs.MPI }}.log + path: build/Testing/Temporary/LastTest.log From 580b68dc2f5160132349fa5d99df855c19ddefe5 Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Mon, 30 Mar 2026 17:26:27 +0200 Subject: [PATCH 08/17] More tests [run ci] --- .github/workflows/test_t8code_macos.yml | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml index 94022c6d43..609dcded98 100644 --- a/.github/workflows/test_t8code_macos.yml +++ b/.github/workflows/test_t8code_macos.yml @@ -74,7 +74,7 @@ jobs: - name: Update packages run: brew update - name: Install missing packages via Homebrew - run: brew install open-mpi ninja cmake + run: brew install open-mpi ninja cmake googletest openssl - name: Show Clang version run: clang --version - name: Show mpicc version @@ -102,12 +102,20 @@ jobs: && echo TEST_LEVEL_FLAG="$TEST_LEVEL_FLAG" >> $GITHUB_ENV - name: build config variables run: | - export CONFIG_OPTIONS="-DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -DCMAKE_Fortran_COMPILER=mpifort -GNinja \ + export CONFIG_OPTIONS="-DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -GNinja \ -DT8CODE_ENABLE_MPI=$MPI -DCMAKE_BUILD_TYPE=$BUILD_TYPE ${TEST_LEVEL_FLAG} -DCMAKE_C_FLAGS_DEBUG=${DEBUG_CONFIG} -DCMAKE_CXX_FLAGS_DEBUG=${DEBUG_CONFIG} \ -DT8CODE_BUILD_PEDANTIC=ON -DT8CODE_BUILD_WALL=ON -DT8CODE_BUILD_WERROR=ON -DT8CODE_BUILD_WEXTRA=ON \ - -DT8CODE_BUILD_FORTRAN_INTERFACE=ON -DT8CODE_BUILD_MESH_HANDLE=ON \ - -DT8CODE_ENABLE_OCC=ON -DT8CODE_ENABLE_VTK=ON -DVTK_DIR=$VTK_INSTALL_PATH/lib/cmake/vtk-9.1" + -DT8CODE_BUILD_FORTRAN_INTERFACE=OFF -DT8CODE_BUILD_MESH_HANDLE=ON \ + -DT8CODE_ENABLE_OCC=ONFF -DT8CODE_ENABLE_VTK=OFF" echo CONFIG_OPTIONS="$CONFIG_OPTIONS" >> $GITHUB_ENV + # - name: build config variables + # run: | + # export CONFIG_OPTIONS="-DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -DCMAKE_Fortran_COMPILER=mpifort -GNinja \ + # -DT8CODE_ENABLE_MPI=$MPI -DCMAKE_BUILD_TYPE=$BUILD_TYPE ${TEST_LEVEL_FLAG} -DCMAKE_C_FLAGS_DEBUG=${DEBUG_CONFIG} -DCMAKE_CXX_FLAGS_DEBUG=${DEBUG_CONFIG} \ + # -DT8CODE_BUILD_PEDANTIC=ON -DT8CODE_BUILD_WALL=ON -DT8CODE_BUILD_WERROR=ON -DT8CODE_BUILD_WEXTRA=ON \ + # -DT8CODE_BUILD_FORTRAN_INTERFACE=ON -DT8CODE_BUILD_MESH_HANDLE=ON \ + # -DT8CODE_ENABLE_OCC=ON -DT8CODE_ENABLE_VTK=ON -DVTK_DIR=$VTK_INSTALL_PATH/lib/cmake/vtk-9.1" + # echo CONFIG_OPTIONS="$CONFIG_OPTIONS" >> $GITHUB_ENV # Run cmake - name: echo cmake line run: echo cmake ../ $CONFIG_OPTIONS From e922dd2815aeb270d6bda5d6f5f1317aea683746 Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Mon, 30 Mar 2026 17:28:16 +0200 Subject: [PATCH 09/17] More tests [run ci] --- .github/workflows/test_t8code_macos.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml index 609dcded98..587578faa3 100644 --- a/.github/workflows/test_t8code_macos.yml +++ b/.github/workflows/test_t8code_macos.yml @@ -106,7 +106,7 @@ jobs: -DT8CODE_ENABLE_MPI=$MPI -DCMAKE_BUILD_TYPE=$BUILD_TYPE ${TEST_LEVEL_FLAG} -DCMAKE_C_FLAGS_DEBUG=${DEBUG_CONFIG} -DCMAKE_CXX_FLAGS_DEBUG=${DEBUG_CONFIG} \ -DT8CODE_BUILD_PEDANTIC=ON -DT8CODE_BUILD_WALL=ON -DT8CODE_BUILD_WERROR=ON -DT8CODE_BUILD_WEXTRA=ON \ -DT8CODE_BUILD_FORTRAN_INTERFACE=OFF -DT8CODE_BUILD_MESH_HANDLE=ON \ - -DT8CODE_ENABLE_OCC=ONFF -DT8CODE_ENABLE_VTK=OFF" + -DT8CODE_ENABLE_OCC=OFF -DT8CODE_ENABLE_VTK=OFF" echo CONFIG_OPTIONS="$CONFIG_OPTIONS" >> $GITHUB_ENV # - name: build config variables # run: | From ebca3b76ee240552d6c94aa63a735614da370a94 Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Mon, 30 Mar 2026 17:30:42 +0200 Subject: [PATCH 10/17] More tests [run ci] --- .github/workflows/test_t8code_macos.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml index 587578faa3..4be027f5c2 100644 --- a/.github/workflows/test_t8code_macos.yml +++ b/.github/workflows/test_t8code_macos.yml @@ -104,7 +104,7 @@ jobs: run: | export CONFIG_OPTIONS="-DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -GNinja \ -DT8CODE_ENABLE_MPI=$MPI -DCMAKE_BUILD_TYPE=$BUILD_TYPE ${TEST_LEVEL_FLAG} -DCMAKE_C_FLAGS_DEBUG=${DEBUG_CONFIG} -DCMAKE_CXX_FLAGS_DEBUG=${DEBUG_CONFIG} \ - -DT8CODE_BUILD_PEDANTIC=ON -DT8CODE_BUILD_WALL=ON -DT8CODE_BUILD_WERROR=ON -DT8CODE_BUILD_WEXTRA=ON \ + -DT8CODE_BUILD_PEDANTIC=ON -DT8CODE_BUILD_WALL=ON -DT8CODE_BUILD_WERROR=OFF -DT8CODE_BUILD_WEXTRA=ON \ -DT8CODE_BUILD_FORTRAN_INTERFACE=OFF -DT8CODE_BUILD_MESH_HANDLE=ON \ -DT8CODE_ENABLE_OCC=OFF -DT8CODE_ENABLE_VTK=OFF" echo CONFIG_OPTIONS="$CONFIG_OPTIONS" >> $GITHUB_ENV From 53dafab3e701c79252d8157a5c8bba01db7103f7 Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Mon, 30 Mar 2026 17:41:16 +0200 Subject: [PATCH 11/17] More tests [run ci] --- .github/workflows/test_t8code_macos.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml index 4be027f5c2..a8a3be8236 100644 --- a/.github/workflows/test_t8code_macos.yml +++ b/.github/workflows/test_t8code_macos.yml @@ -102,7 +102,7 @@ jobs: && echo TEST_LEVEL_FLAG="$TEST_LEVEL_FLAG" >> $GITHUB_ENV - name: build config variables run: | - export CONFIG_OPTIONS="-DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -GNinja \ + export CONFIG_OPTIONS="-DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -GNinja -DCMAKE_INSTALL_PREFIX=$(pwd)/install \ -DT8CODE_ENABLE_MPI=$MPI -DCMAKE_BUILD_TYPE=$BUILD_TYPE ${TEST_LEVEL_FLAG} -DCMAKE_C_FLAGS_DEBUG=${DEBUG_CONFIG} -DCMAKE_CXX_FLAGS_DEBUG=${DEBUG_CONFIG} \ -DT8CODE_BUILD_PEDANTIC=ON -DT8CODE_BUILD_WALL=ON -DT8CODE_BUILD_WERROR=OFF -DT8CODE_BUILD_WEXTRA=ON \ -DT8CODE_BUILD_FORTRAN_INTERFACE=OFF -DT8CODE_BUILD_MESH_HANDLE=ON \ From db6aef0e428c7766c25118d250d377ed1ac6d18d Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Tue, 31 Mar 2026 09:27:12 +0200 Subject: [PATCH 12/17] Try only parallel tests [run ci] --- .github/workflows/test_t8code_macos.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml index a8a3be8236..347fb6432a 100644 --- a/.github/workflows/test_t8code_macos.yml +++ b/.github/workflows/test_t8code_macos.yml @@ -136,9 +136,9 @@ jobs: # # Part 3: Run t8code tests # ------------------------ - - name: serial tests (if MPI is enabled) - run: cd build && ctest $MAKEFLAGS -R _serial - if: ${{ inputs.MPI == 'ON' }} + # - name: serial tests (if MPI is enabled) + # run: cd build && ctest $MAKEFLAGS -R _serial + # if: ${{ inputs.MPI == 'ON' }} - name: parallel tests (if MPI is enabled) run: cd build && ctest -R _parallel env: From 121e61f4dac050dccbe3af45b2ff5793046d6edc Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Tue, 31 Mar 2026 12:22:01 +0200 Subject: [PATCH 13/17] More tests [run ci] --- .github/workflows/test_t8code_macos.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml index 347fb6432a..b9cd8a544b 100644 --- a/.github/workflows/test_t8code_macos.yml +++ b/.github/workflows/test_t8code_macos.yml @@ -103,7 +103,8 @@ jobs: - name: build config variables run: | export CONFIG_OPTIONS="-DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -GNinja -DCMAKE_INSTALL_PREFIX=$(pwd)/install \ - -DT8CODE_ENABLE_MPI=$MPI -DCMAKE_BUILD_TYPE=$BUILD_TYPE ${TEST_LEVEL_FLAG} -DCMAKE_C_FLAGS_DEBUG=${DEBUG_CONFIG} -DCMAKE_CXX_FLAGS_DEBUG=${DEBUG_CONFIG} \ + -DT8CODE_ENABLE_MPI=$MPI -DMPIEXEC_PREFLAGS=--oversubscribe -DCMAKE_BUILD_TYPE=$BUILD_TYPE ${TEST_LEVEL_FLAG} \ + -DCMAKE_C_FLAGS_DEBUG=${DEBUG_CONFIG} -DCMAKE_CXX_FLAGS_DEBUG=${DEBUG_CONFIG} \ -DT8CODE_BUILD_PEDANTIC=ON -DT8CODE_BUILD_WALL=ON -DT8CODE_BUILD_WERROR=OFF -DT8CODE_BUILD_WEXTRA=ON \ -DT8CODE_BUILD_FORTRAN_INTERFACE=OFF -DT8CODE_BUILD_MESH_HANDLE=ON \ -DT8CODE_ENABLE_OCC=OFF -DT8CODE_ENABLE_VTK=OFF" @@ -138,7 +139,7 @@ jobs: # ------------------------ # - name: serial tests (if MPI is enabled) # run: cd build && ctest $MAKEFLAGS -R _serial - # if: ${{ inputs.MPI == 'ON' }} + if: ${{ inputs.MPI == 'ON' }} - name: parallel tests (if MPI is enabled) run: cd build && ctest -R _parallel env: From a5a987e483ab132d3e27e8573503c49cf6161bbb Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Tue, 31 Mar 2026 12:35:52 +0200 Subject: [PATCH 14/17] More tests [run ci] --- .github/workflows/test_t8code_macos.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml index b9cd8a544b..bf09b1fb65 100644 --- a/.github/workflows/test_t8code_macos.yml +++ b/.github/workflows/test_t8code_macos.yml @@ -107,7 +107,13 @@ jobs: -DCMAKE_C_FLAGS_DEBUG=${DEBUG_CONFIG} -DCMAKE_CXX_FLAGS_DEBUG=${DEBUG_CONFIG} \ -DT8CODE_BUILD_PEDANTIC=ON -DT8CODE_BUILD_WALL=ON -DT8CODE_BUILD_WERROR=OFF -DT8CODE_BUILD_WEXTRA=ON \ -DT8CODE_BUILD_FORTRAN_INTERFACE=OFF -DT8CODE_BUILD_MESH_HANDLE=ON \ - -DT8CODE_ENABLE_OCC=OFF -DT8CODE_ENABLE_VTK=OFF" + -DT8CODE_ENABLE_OCC=OFF -DT8CODE_ENABLE_VTK=OFF" \ + -DCTEST_PARALLEL_LEVEL=4 \ + -DENV_OMPI_ALLOW_RUN_AS_ROOT=1 \ + -DENV_OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 \ + -DENV_OMPI_MCA_btl=self,tcp \ + -DENV_OMPI_MCA_pml=ob1 \ + -DENV_OMPI_MCA_rmaps_base_oversubscribe=1 echo CONFIG_OPTIONS="$CONFIG_OPTIONS" >> $GITHUB_ENV # - name: build config variables # run: | From d1ebefa0cd4d8583519b31b508a089ec74dd42cc Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Tue, 31 Mar 2026 12:44:25 +0200 Subject: [PATCH 15/17] More tests [run ci] --- .github/workflows/test_t8code_macos.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml index bf09b1fb65..2c1c8b5d3b 100644 --- a/.github/workflows/test_t8code_macos.yml +++ b/.github/workflows/test_t8code_macos.yml @@ -107,13 +107,13 @@ jobs: -DCMAKE_C_FLAGS_DEBUG=${DEBUG_CONFIG} -DCMAKE_CXX_FLAGS_DEBUG=${DEBUG_CONFIG} \ -DT8CODE_BUILD_PEDANTIC=ON -DT8CODE_BUILD_WALL=ON -DT8CODE_BUILD_WERROR=OFF -DT8CODE_BUILD_WEXTRA=ON \ -DT8CODE_BUILD_FORTRAN_INTERFACE=OFF -DT8CODE_BUILD_MESH_HANDLE=ON \ - -DT8CODE_ENABLE_OCC=OFF -DT8CODE_ENABLE_VTK=OFF" \ + -DT8CODE_ENABLE_OCC=OFF -DT8CODE_ENABLE_VTK=OFF \ -DCTEST_PARALLEL_LEVEL=4 \ -DENV_OMPI_ALLOW_RUN_AS_ROOT=1 \ -DENV_OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 \ -DENV_OMPI_MCA_btl=self,tcp \ -DENV_OMPI_MCA_pml=ob1 \ - -DENV_OMPI_MCA_rmaps_base_oversubscribe=1 + -DENV_OMPI_MCA_rmaps_base_oversubscribe=1" echo CONFIG_OPTIONS="$CONFIG_OPTIONS" >> $GITHUB_ENV # - name: build config variables # run: | From 6cdca1e3724db6c6dce78dc894d0d19065db8e82 Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Tue, 31 Mar 2026 12:53:09 +0200 Subject: [PATCH 16/17] More tests [run ci] --- .github/workflows/test_t8code_macos.yml | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml index 2c1c8b5d3b..b54c8de82b 100644 --- a/.github/workflows/test_t8code_macos.yml +++ b/.github/workflows/test_t8code_macos.yml @@ -102,18 +102,11 @@ jobs: && echo TEST_LEVEL_FLAG="$TEST_LEVEL_FLAG" >> $GITHUB_ENV - name: build config variables run: | - export CONFIG_OPTIONS="-DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -GNinja -DCMAKE_INSTALL_PREFIX=$(pwd)/install \ - -DT8CODE_ENABLE_MPI=$MPI -DMPIEXEC_PREFLAGS=--oversubscribe -DCMAKE_BUILD_TYPE=$BUILD_TYPE ${TEST_LEVEL_FLAG} \ - -DCMAKE_C_FLAGS_DEBUG=${DEBUG_CONFIG} -DCMAKE_CXX_FLAGS_DEBUG=${DEBUG_CONFIG} \ + export CONFIG_OPTIONS="-DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -GNinja \ + -DT8CODE_ENABLE_MPI=$MPI -DCMAKE_BUILD_TYPE=$BUILD_TYPE ${TEST_LEVEL_FLAG} -DCMAKE_C_FLAGS_DEBUG=${DEBUG_CONFIG} -DCMAKE_CXX_FLAGS_DEBUG=${DEBUG_CONFIG} \ -DT8CODE_BUILD_PEDANTIC=ON -DT8CODE_BUILD_WALL=ON -DT8CODE_BUILD_WERROR=OFF -DT8CODE_BUILD_WEXTRA=ON \ -DT8CODE_BUILD_FORTRAN_INTERFACE=OFF -DT8CODE_BUILD_MESH_HANDLE=ON \ - -DT8CODE_ENABLE_OCC=OFF -DT8CODE_ENABLE_VTK=OFF \ - -DCTEST_PARALLEL_LEVEL=4 \ - -DENV_OMPI_ALLOW_RUN_AS_ROOT=1 \ - -DENV_OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 \ - -DENV_OMPI_MCA_btl=self,tcp \ - -DENV_OMPI_MCA_pml=ob1 \ - -DENV_OMPI_MCA_rmaps_base_oversubscribe=1" + -DT8CODE_ENABLE_OCC=OFF -DT8CODE_ENABLE_VTK=OFF" echo CONFIG_OPTIONS="$CONFIG_OPTIONS" >> $GITHUB_ENV # - name: build config variables # run: | @@ -147,7 +140,13 @@ jobs: # run: cd build && ctest $MAKEFLAGS -R _serial if: ${{ inputs.MPI == 'ON' }} - name: parallel tests (if MPI is enabled) - run: cd build && ctest -R _parallel + run: | + export OMPI_ALLOW_RUN_AS_ROOT=1 + export OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 + export OMPI_MCA_btl=self,tcp + export OMPI_MCA_pml=ob1 + export OMPI_MCA_rmaps_base_oversubscribe=1 + cd build && ctest -R _parallel env: # Note: These openmpi options are required to ensure stable runs in github workflows and avoid stalling. # In particular, they activate oversubscription and define the communication channels, here tcp (and self). From 953c6d856d059d9726a354da8c803bcfba3f1baf Mon Sep 17 00:00:00 2001 From: Thomas Spenke Date: Tue, 31 Mar 2026 13:08:59 +0200 Subject: [PATCH 17/17] More tests [run ci] --- .github/workflows/test_t8code_macos.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test_t8code_macos.yml b/.github/workflows/test_t8code_macos.yml index b54c8de82b..9a9693f4a7 100644 --- a/.github/workflows/test_t8code_macos.yml +++ b/.github/workflows/test_t8code_macos.yml @@ -102,7 +102,7 @@ jobs: && echo TEST_LEVEL_FLAG="$TEST_LEVEL_FLAG" >> $GITHUB_ENV - name: build config variables run: | - export CONFIG_OPTIONS="-DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -GNinja \ + export CONFIG_OPTIONS="-DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpicxx -GNinja -DCMAKE_INSTALL_PREFIX=$(pwd)/install \\ -DT8CODE_ENABLE_MPI=$MPI -DCMAKE_BUILD_TYPE=$BUILD_TYPE ${TEST_LEVEL_FLAG} -DCMAKE_C_FLAGS_DEBUG=${DEBUG_CONFIG} -DCMAKE_CXX_FLAGS_DEBUG=${DEBUG_CONFIG} \ -DT8CODE_BUILD_PEDANTIC=ON -DT8CODE_BUILD_WALL=ON -DT8CODE_BUILD_WERROR=OFF -DT8CODE_BUILD_WEXTRA=ON \ -DT8CODE_BUILD_FORTRAN_INTERFACE=OFF -DT8CODE_BUILD_MESH_HANDLE=ON \