From 259ad057458e18d1d0758bd9ab9b734ddd219e43 Mon Sep 17 00:00:00 2001 From: reneSchm <49305466+reneSchm@users.noreply.github.com> Date: Tue, 26 Aug 2025 12:18:08 +0200 Subject: [PATCH 01/17] fix build --- .github/actions/build-py/action.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/actions/build-py/action.yml b/.github/actions/build-py/action.yml index 941eded182..fa21926c48 100644 --- a/.github/actions/build-py/action.yml +++ b/.github/actions/build-py/action.yml @@ -19,8 +19,8 @@ runs: shell: bash run: | cd pycode/memilio-${{ inputs.package }}/ - /opt/python/cp38-cp38/bin/python setup.py bdist_wheel - /opt/python/cp311-cp311/bin/python setup.py bdist_wheel + /opt/python/cp38-cp38/bin/python -m build + /opt/python/cp311-cp311/bin/python -m build # Exclude memilio-generation, because its a pure python package, cmake is only used in the build process to retrieve data from cpp if [[ -f "CMakeLists.txt" ]] && [ "${{ inputs.package }}" != "generation" ]; then # includes native dependencies in the wheel @@ -35,4 +35,3 @@ runs: with: name: python-wheels-${{ inputs.package }} path: pycode/wheelhouse - From 24b3b6a26a20f895d5b02aca574f5ee73cd90075 Mon Sep 17 00:00:00 2001 From: reneSchm <49305466+reneSchm@users.noreply.github.com> Date: Tue, 26 Aug 2025 12:28:43 +0200 Subject: [PATCH 02/17] try fix missing pip --- .github/actions/build-py/action.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/actions/build-py/action.yml b/.github/actions/build-py/action.yml index fa21926c48..688c306542 100644 --- a/.github/actions/build-py/action.yml +++ b/.github/actions/build-py/action.yml @@ -19,8 +19,8 @@ runs: shell: bash run: | cd pycode/memilio-${{ inputs.package }}/ - /opt/python/cp38-cp38/bin/python -m build - /opt/python/cp311-cp311/bin/python -m build + /opt/python/cp38-cp38/bin/python -m build --no-isolation + /opt/python/cp311-cp311/bin/python -m build --no-isolation # Exclude memilio-generation, because its a pure python package, cmake is only used in the build process to retrieve data from cpp if [[ -f "CMakeLists.txt" ]] && [ "${{ inputs.package }}" != "generation" ]; then # includes native dependencies in the wheel From 3f63ac1d9407d3d3a74c773de80199eeb588b722 Mon Sep 17 00:00:00 2001 From: reneSchm <49305466+reneSchm@users.noreply.github.com> Date: Tue, 26 Aug 2025 12:30:37 +0200 Subject: [PATCH 03/17] [tmp] disable non py-build actions --- .github/workflows/main.yml | 490 ++++++++++++++++++------------------- 1 file changed, 245 insertions(+), 245 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 9b0c6505ea..6c02ac9616 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -22,240 +22,240 @@ concurrency: cancel-in-progress: true jobs: - pre-commit: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 - with: - python-version: 3.11 - - uses: pre-commit/action@v3.0.1 + # pre-commit: + # runs-on: ubuntu-latest + # steps: + # - uses: actions/checkout@v4 + # - uses: actions/setup-python@v5 + # with: + # python-version: 3.11 + # - uses: pre-commit/action@v3.0.1 - build-cpp-gcc_clang: - if: github.event.pull_request.draft == false - strategy: - matrix: - compiler: ["gcc", "clang"] - config: ["Debug", "Release"] - version: ["latest", "min"] - include: - - version: "latest" - os: "ubuntu-latest" - - version: "min" - os: "ubuntu-22.04" - runs-on: ${{ matrix.os }} - steps: - - uses: actions/checkout@v4 - - uses: ./.github/actions/linux-build - with: - compiler: ${{ matrix.compiler }} - config: ${{ matrix.config }} - version: ${{ matrix.version }} - coverage: ${{ (matrix.compiler == 'gcc' && matrix.config == 'Debug' && matrix.version == 'latest') && 'ON' || 'OFF' }} # `c && t || f` is (usually) equivalent to `c ? t : f` - sanitizers: ${{ (matrix.compiler == 'gcc' && matrix.config == 'Debug' && matrix.version == 'latest') && 'ON' || 'OFF' }} + # build-cpp-gcc_clang: + # if: github.event.pull_request.draft == false + # strategy: + # matrix: + # compiler: ["gcc", "clang"] + # config: ["Debug", "Release"] + # version: ["latest", "min"] + # include: + # - version: "latest" + # os: "ubuntu-latest" + # - version: "min" + # os: "ubuntu-22.04" + # runs-on: ${{ matrix.os }} + # steps: + # - uses: actions/checkout@v4 + # - uses: ./.github/actions/linux-build + # with: + # compiler: ${{ matrix.compiler }} + # config: ${{ matrix.config }} + # version: ${{ matrix.version }} + # coverage: ${{ (matrix.compiler == 'gcc' && matrix.config == 'Debug' && matrix.version == 'latest') && 'ON' || 'OFF' }} # `c && t || f` is (usually) equivalent to `c ? t : f` + # sanitizers: ${{ (matrix.compiler == 'gcc' && matrix.config == 'Debug' && matrix.version == 'latest') && 'ON' || 'OFF' }} - build-cpp-gcc-no-optional-deps: - if: github.event.pull_request.draft == false - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: ./.github/actions/linux-build - with: - compiler: gcc - version: latest - config: Release - optional-dependencies: OFF + # build-cpp-gcc-no-optional-deps: + # if: github.event.pull_request.draft == false + # runs-on: ubuntu-latest + # steps: + # - uses: actions/checkout@v4 + # - uses: ./.github/actions/linux-build + # with: + # compiler: gcc + # version: latest + # config: Release + # optional-dependencies: OFF - build-cpp-gcc-openmp: - if: github.event.pull_request.draft == false - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: ./.github/actions/linux-build - with: - compiler: gcc - version: latest - config: Release - openmp: ON + # build-cpp-gcc-openmp: + # if: github.event.pull_request.draft == false + # runs-on: ubuntu-latest + # steps: + # - uses: actions/checkout@v4 + # - uses: ./.github/actions/linux-build + # with: + # compiler: gcc + # version: latest + # config: Release + # openmp: ON - build-cpp-msvc: - if: github.event.pull_request.draft == false - strategy: - matrix: - config: ["Debug", "Release"] - version: ["latest", "min"] - include: - - version: "latest" - os: "windows-2025" - - version: "min" - os: "windows-2022" - runs-on: ${{ matrix.os }} - steps: - - uses: actions/checkout@v4 - - uses: ./.github/actions/windows-build - with: - config: ${{ matrix.config }} - version: ${{ matrix.version }} + # build-cpp-msvc: + # if: github.event.pull_request.draft == false + # strategy: + # matrix: + # config: ["Debug", "Release"] + # version: ["latest", "min"] + # include: + # - version: "latest" + # os: "windows-2025" + # - version: "min" + # os: "windows-2022" + # runs-on: ${{ matrix.os }} + # steps: + # - uses: actions/checkout@v4 + # - uses: ./.github/actions/windows-build + # with: + # config: ${{ matrix.config }} + # version: ${{ matrix.version }} - build-cpp-msvc-no-optional-deps: - if: github.event.pull_request.draft == false - runs-on: windows-2025 - steps: - - uses: actions/checkout@v4 - - uses: ./.github/actions/windows-build - with: - config: Release - version: latest - optional-dependencies: OFF + # build-cpp-msvc-no-optional-deps: + # if: github.event.pull_request.draft == false + # runs-on: windows-2025 + # steps: + # - uses: actions/checkout@v4 + # - uses: ./.github/actions/windows-build + # with: + # config: Release + # version: latest + # optional-dependencies: OFF - test-cpp-gcc_clang: - if: github.event.pull_request.draft == false - needs: build-cpp-gcc_clang - strategy: - matrix: - compiler: ["gcc", "clang"] - config: ["Debug", "Release"] - version: ["latest", "min"] - include: - - version: "latest" - os: "ubuntu-latest" - - version: "min" - os: "ubuntu-22.04" - runs-on: ${{ matrix.os }} - steps: - - uses: actions/checkout@v4 - - uses: ./.github/actions/linux-test - with: - artifact-pattern: ${{ matrix.compiler }}-${{ matrix.version }}-${{ matrix.config }} - coverage: ${{ (matrix.compiler == 'gcc' && matrix.version == 'latest' && matrix.config == 'Debug') && 'ON' || 'OFF' }} + # test-cpp-gcc_clang: + # if: github.event.pull_request.draft == false + # needs: build-cpp-gcc_clang + # strategy: + # matrix: + # compiler: ["gcc", "clang"] + # config: ["Debug", "Release"] + # version: ["latest", "min"] + # include: + # - version: "latest" + # os: "ubuntu-latest" + # - version: "min" + # os: "ubuntu-22.04" + # runs-on: ${{ matrix.os }} + # steps: + # - uses: actions/checkout@v4 + # - uses: ./.github/actions/linux-test + # with: + # artifact-pattern: ${{ matrix.compiler }}-${{ matrix.version }}-${{ matrix.config }} + # coverage: ${{ (matrix.compiler == 'gcc' && matrix.version == 'latest' && matrix.config == 'Debug') && 'ON' || 'OFF' }} - test-cpp-gcc-sbml: - if: github.event.pull_request.draft == false - needs: build-cpp-gcc_clang - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: ./.github/actions/sbml-test + # test-cpp-gcc-sbml: + # if: github.event.pull_request.draft == false + # needs: build-cpp-gcc_clang + # runs-on: ubuntu-latest + # steps: + # - uses: actions/checkout@v4 + # - uses: ./.github/actions/sbml-test - merge-test-artifacts: - needs: [test-cpp-gcc_clang, test-cpp-msvc, test-py-surrogatemodel] - runs-on: ubuntu-latest - steps: - - name: merge-coverage-artifacts - uses: actions/upload-artifact/merge@v4 - with: - name: test-cpp-coverage-reports - pattern: test-cpp-coverage-reports-* - - name: merge-linux-artifacts - uses: actions/upload-artifact/merge@v4 - with: - name: test-cpp-linux-report - pattern: test-cpp-linux-report-* - - name: merge-windows-artifacts - uses: actions/upload-artifact/merge@v4 - with: - name: test-cpp-win-report - pattern: test-cpp-win-report-* - - name: merge python reports - uses: actions/upload-artifact/merge@v4 - with: - name: test-py-coverage-reports-surrogatemodel - pattern: test-py-coverage-reports-surrogatemodel-* + # merge-test-artifacts: + # needs: [test-cpp-gcc_clang, test-cpp-msvc, test-py-surrogatemodel] + # runs-on: ubuntu-latest + # steps: + # - name: merge-coverage-artifacts + # uses: actions/upload-artifact/merge@v4 + # with: + # name: test-cpp-coverage-reports + # pattern: test-cpp-coverage-reports-* + # - name: merge-linux-artifacts + # uses: actions/upload-artifact/merge@v4 + # with: + # name: test-cpp-linux-report + # pattern: test-cpp-linux-report-* + # - name: merge-windows-artifacts + # uses: actions/upload-artifact/merge@v4 + # with: + # name: test-cpp-win-report + # pattern: test-cpp-win-report-* + # - name: merge python reports + # uses: actions/upload-artifact/merge@v4 + # with: + # name: test-py-coverage-reports-surrogatemodel + # pattern: test-py-coverage-reports-surrogatemodel-* - test-cpp-gcc-no-optional-deps: - if: github.event.pull_request.draft == false - needs: build-cpp-gcc-no-optional-deps - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: ./.github/actions/linux-test - with: - artifact-pattern: gcc-latest-Release - optional-deps: OFF + # test-cpp-gcc-no-optional-deps: + # if: github.event.pull_request.draft == false + # needs: build-cpp-gcc-no-optional-deps + # runs-on: ubuntu-latest + # steps: + # - uses: actions/checkout@v4 + # - uses: ./.github/actions/linux-test + # with: + # artifact-pattern: gcc-latest-Release + # optional-deps: OFF - test-cpp-gcc-openmp: - if: github.event.pull_request.draft == false - needs: build-cpp-gcc-openmp - runs-on: ubuntu-latest - timeout-minutes: 30 - env: - OMP_NUM_THREADS: 4 - steps: - - uses: actions/checkout@v4 - - uses: ./.github/actions/linux-test - with: - artifact-pattern: gcc-latest-Release - num-repeat: 10 - openmp: ON + # test-cpp-gcc-openmp: + # if: github.event.pull_request.draft == false + # needs: build-cpp-gcc-openmp + # runs-on: ubuntu-latest + # timeout-minutes: 30 + # env: + # OMP_NUM_THREADS: 4 + # steps: + # - uses: actions/checkout@v4 + # - uses: ./.github/actions/linux-test + # with: + # artifact-pattern: gcc-latest-Release + # num-repeat: 10 + # openmp: ON - test-cpp-msvc: - if: github.event.pull_request.draft == false - needs: build-cpp-msvc - strategy: - matrix: - config: ["Debug", "Release"] - version: ["latest", "min"] - include: - - version: "latest" - os: "windows-2025" - - version: "min" - os: "windows-2022" - runs-on: ${{ matrix.os }} - steps: - - uses: actions/checkout@v4 - - uses: ./.github/actions/windows-test - with: - artifact-pattern: msvc-${{ matrix.version }}-${{ matrix.config }} + # test-cpp-msvc: + # if: github.event.pull_request.draft == false + # needs: build-cpp-msvc + # strategy: + # matrix: + # config: ["Debug", "Release"] + # version: ["latest", "min"] + # include: + # - version: "latest" + # os: "windows-2025" + # - version: "min" + # os: "windows-2022" + # runs-on: ${{ matrix.os }} + # steps: + # - uses: actions/checkout@v4 + # - uses: ./.github/actions/windows-test + # with: + # artifact-pattern: msvc-${{ matrix.version }}-${{ matrix.config }} - test-cpp-msvc-no-optional-deps: - if: github.event.pull_request.draft == false - needs: build-cpp-msvc-no-optional-deps - runs-on: windows-2025 - steps: - - uses: actions/checkout@v4 - - uses: ./.github/actions/windows-test - with: - artifact-pattern: msvc-latest-Release - optional-deps: OFF + # test-cpp-msvc-no-optional-deps: + # if: github.event.pull_request.draft == false + # needs: build-cpp-msvc-no-optional-deps + # runs-on: windows-2025 + # steps: + # - uses: actions/checkout@v4 + # - uses: ./.github/actions/windows-test + # with: + # artifact-pattern: msvc-latest-Release + # optional-deps: OFF - run_examples-cpp-gcc_clang: - if: github.event.pull_request.draft == false - needs: build-cpp-gcc_clang - strategy: - matrix: - compiler: ["gcc", "clang"] - config: ["Debug", "Release"] - version: ["latest", "min"] - include: - - version: "latest" - os: "ubuntu-latest" - - version: "min" - os: "ubuntu-22.04" - runs-on: ${{ matrix.os }} - steps: - - uses: actions/checkout@v4 - - uses: ./.github/actions/linux-run_examples - with: - build-artifact: build-cpp-linux-${{ matrix.compiler }}-${{ matrix.version }}-${{ matrix.config }} + # run_examples-cpp-gcc_clang: + # if: github.event.pull_request.draft == false + # needs: build-cpp-gcc_clang + # strategy: + # matrix: + # compiler: ["gcc", "clang"] + # config: ["Debug", "Release"] + # version: ["latest", "min"] + # include: + # - version: "latest" + # os: "ubuntu-latest" + # - version: "min" + # os: "ubuntu-22.04" + # runs-on: ${{ matrix.os }} + # steps: + # - uses: actions/checkout@v4 + # - uses: ./.github/actions/linux-run_examples + # with: + # build-artifact: build-cpp-linux-${{ matrix.compiler }}-${{ matrix.version }}-${{ matrix.config }} - run_examples-cpp-msvc: - if: github.event.pull_request.draft == false - needs: build-cpp-msvc - strategy: - matrix: - config: ["Debug", "Release"] - version: ["latest", "min"] - include: - - version: "latest" - os: "windows-2025" - - version: "min" - os: "windows-2022" - runs-on: ${{ matrix.os }} - steps: - - uses: actions/checkout@v4 - - uses: ./.github/actions/windows-run_examples - with: - build-artifact: build-cpp-windows-msvc-${{ matrix.version }}-${{ matrix.config }} + # run_examples-cpp-msvc: + # if: github.event.pull_request.draft == false + # needs: build-cpp-msvc + # strategy: + # matrix: + # config: ["Debug", "Release"] + # version: ["latest", "min"] + # include: + # - version: "latest" + # os: "windows-2025" + # - version: "min" + # os: "windows-2022" + # runs-on: ${{ matrix.os }} + # steps: + # - uses: actions/checkout@v4 + # - uses: ./.github/actions/windows-run_examples + # with: + # build-artifact: build-cpp-windows-msvc-${{ matrix.version }}-${{ matrix.config }} build-py-generation: if: github.event.pull_request.draft == false @@ -328,28 +328,28 @@ jobs: package: surrogatemodel coverage: ON - codecov: - if: github.event.pull_request.draft == false - needs: merge-test-artifacts - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Install dependencies - run: | - sudo apt-get -qq update - sudo apt-get -qq -y install git curl - - name: Download python coverage report - uses: actions/download-artifact@v4 - with: - name: test-py-coverage-reports-surrogatemodel - - name: Download cpp coverage report - uses: actions/download-artifact@v4 - with: - name: test-cpp-coverage-reports - - name: Deploy to codecov.io - uses: codecov/codecov-action@v3 - with: - token: ${{ secrets.CODECOV_TOKEN }} - directory: ./coverage_python - files: ./coverage_python/**,./coverage.info - verbose: true + # codecov: + # if: github.event.pull_request.draft == false + # needs: merge-test-artifacts + # runs-on: ubuntu-latest + # steps: + # - uses: actions/checkout@v4 + # - name: Install dependencies + # run: | + # sudo apt-get -qq update + # sudo apt-get -qq -y install git curl + # - name: Download python coverage report + # uses: actions/download-artifact@v4 + # with: + # name: test-py-coverage-reports-surrogatemodel + # - name: Download cpp coverage report + # uses: actions/download-artifact@v4 + # with: + # name: test-cpp-coverage-reports + # - name: Deploy to codecov.io + # uses: codecov/codecov-action@v3 + # with: + # token: ${{ secrets.CODECOV_TOKEN }} + # directory: ./coverage_python + # files: ./coverage_python/**,./coverage.info + # verbose: true From 2011b0554b153d8c8f8975b1b8df041a87c7a367 Mon Sep 17 00:00:00 2001 From: reneSchm <49305466+reneSchm@users.noreply.github.com> Date: Tue, 26 Aug 2025 13:35:25 +0200 Subject: [PATCH 04/17] try ensurepip --- .github/actions/build-py/action.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/actions/build-py/action.yml b/.github/actions/build-py/action.yml index 688c306542..c926d83c4b 100644 --- a/.github/actions/build-py/action.yml +++ b/.github/actions/build-py/action.yml @@ -19,8 +19,10 @@ runs: shell: bash run: | cd pycode/memilio-${{ inputs.package }}/ - /opt/python/cp38-cp38/bin/python -m build --no-isolation - /opt/python/cp311-cp311/bin/python -m build --no-isolation + /opt/python/cp38-cp38/bin/python -m ensurepip --upgrade + /opt/python/cp38-cp38/bin/python -m build + /opt/python/cp311-cp311/bin/python -m ensurepip --upgrade + /opt/python/cp311-cp311/bin/python -m build # Exclude memilio-generation, because its a pure python package, cmake is only used in the build process to retrieve data from cpp if [[ -f "CMakeLists.txt" ]] && [ "${{ inputs.package }}" != "generation" ]; then # includes native dependencies in the wheel From aa5784f1b8dcf571384087e79c3fa7e177645ac7 Mon Sep 17 00:00:00 2001 From: reneSchm <49305466+reneSchm@users.noreply.github.com> Date: Tue, 26 Aug 2025 13:59:46 +0200 Subject: [PATCH 05/17] more args --- .github/actions/build-py/action.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/actions/build-py/action.yml b/.github/actions/build-py/action.yml index c926d83c4b..5cc8343d63 100644 --- a/.github/actions/build-py/action.yml +++ b/.github/actions/build-py/action.yml @@ -20,9 +20,9 @@ runs: run: | cd pycode/memilio-${{ inputs.package }}/ /opt/python/cp38-cp38/bin/python -m ensurepip --upgrade - /opt/python/cp38-cp38/bin/python -m build + /opt/python/cp38-cp38/bin/python -m build --no-isolation --installer pip /opt/python/cp311-cp311/bin/python -m ensurepip --upgrade - /opt/python/cp311-cp311/bin/python -m build + /opt/python/cp311-cp311/bin/python -m build --no-isolation --installer pip # Exclude memilio-generation, because its a pure python package, cmake is only used in the build process to retrieve data from cpp if [[ -f "CMakeLists.txt" ]] && [ "${{ inputs.package }}" != "generation" ]; then # includes native dependencies in the wheel From bfbe5292f436260b84105aae42c40ef92baee27c Mon Sep 17 00:00:00 2001 From: reneSchm <49305466+reneSchm@users.noreply.github.com> Date: Tue, 26 Aug 2025 14:03:07 +0200 Subject: [PATCH 06/17] args --- .github/actions/build-py/action.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/actions/build-py/action.yml b/.github/actions/build-py/action.yml index 5cc8343d63..dfc2effc92 100644 --- a/.github/actions/build-py/action.yml +++ b/.github/actions/build-py/action.yml @@ -20,9 +20,9 @@ runs: run: | cd pycode/memilio-${{ inputs.package }}/ /opt/python/cp38-cp38/bin/python -m ensurepip --upgrade - /opt/python/cp38-cp38/bin/python -m build --no-isolation --installer pip + /opt/python/cp38-cp38/bin/python -m build --installer pip /opt/python/cp311-cp311/bin/python -m ensurepip --upgrade - /opt/python/cp311-cp311/bin/python -m build --no-isolation --installer pip + /opt/python/cp311-cp311/bin/python -m build --installer pip # Exclude memilio-generation, because its a pure python package, cmake is only used in the build process to retrieve data from cpp if [[ -f "CMakeLists.txt" ]] && [ "${{ inputs.package }}" != "generation" ]; then # includes native dependencies in the wheel From 386c0fca65d1ff439dc29253a29b5d2b2f7da32b Mon Sep 17 00:00:00 2001 From: reneSchm <49305466+reneSchm@users.noreply.github.com> Date: Tue, 26 Aug 2025 14:06:26 +0200 Subject: [PATCH 07/17] install scikit-build manually --- .github/actions/build-py/action.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/actions/build-py/action.yml b/.github/actions/build-py/action.yml index dfc2effc92..b9b93c70d9 100644 --- a/.github/actions/build-py/action.yml +++ b/.github/actions/build-py/action.yml @@ -19,10 +19,10 @@ runs: shell: bash run: | cd pycode/memilio-${{ inputs.package }}/ - /opt/python/cp38-cp38/bin/python -m ensurepip --upgrade - /opt/python/cp38-cp38/bin/python -m build --installer pip - /opt/python/cp311-cp311/bin/python -m ensurepip --upgrade - /opt/python/cp311-cp311/bin/python -m build --installer pip + /opt/python/cp38-cp38/bin/python -m pip install scikit-build + /opt/python/cp38-cp38/bin/python -m build + /opt/python/cp311-cp311/bin/python -m pip install scikit-build + /opt/python/cp311-cp311/bin/python -m build # Exclude memilio-generation, because its a pure python package, cmake is only used in the build process to retrieve data from cpp if [[ -f "CMakeLists.txt" ]] && [ "${{ inputs.package }}" != "generation" ]; then # includes native dependencies in the wheel From fc1f386643de9c709814c266c0bfe2d5b870ef9d Mon Sep 17 00:00:00 2001 From: reneSchm <49305466+reneSchm@users.noreply.github.com> Date: Tue, 26 Aug 2025 14:09:44 +0200 Subject: [PATCH 08/17] set installer --- .github/actions/build-py/action.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/actions/build-py/action.yml b/.github/actions/build-py/action.yml index b9b93c70d9..981771aa17 100644 --- a/.github/actions/build-py/action.yml +++ b/.github/actions/build-py/action.yml @@ -19,10 +19,10 @@ runs: shell: bash run: | cd pycode/memilio-${{ inputs.package }}/ - /opt/python/cp38-cp38/bin/python -m pip install scikit-build - /opt/python/cp38-cp38/bin/python -m build + /opt/python/cp38-cp311/bin/python -m pip install scikit-build + /opt/python/cp38-cp38/bin/python -m build --installer pip /opt/python/cp311-cp311/bin/python -m pip install scikit-build - /opt/python/cp311-cp311/bin/python -m build + /opt/python/cp311-cp311/bin/python -m build --installer pip # Exclude memilio-generation, because its a pure python package, cmake is only used in the build process to retrieve data from cpp if [[ -f "CMakeLists.txt" ]] && [ "${{ inputs.package }}" != "generation" ]; then # includes native dependencies in the wheel From 3e56f5b0d2f16fb25e3f72e2adf3e96db76e2346 Mon Sep 17 00:00:00 2001 From: reneSchm <49305466+reneSchm@users.noreply.github.com> Date: Tue, 26 Aug 2025 14:14:35 +0200 Subject: [PATCH 09/17] fix path --- .github/actions/build-py/action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/actions/build-py/action.yml b/.github/actions/build-py/action.yml index 981771aa17..f2dc707410 100644 --- a/.github/actions/build-py/action.yml +++ b/.github/actions/build-py/action.yml @@ -19,7 +19,7 @@ runs: shell: bash run: | cd pycode/memilio-${{ inputs.package }}/ - /opt/python/cp38-cp311/bin/python -m pip install scikit-build + /opt/python/cp38-cp38/bin/python -m pip install scikit-build /opt/python/cp38-cp38/bin/python -m build --installer pip /opt/python/cp311-cp311/bin/python -m pip install scikit-build /opt/python/cp311-cp311/bin/python -m build --installer pip From e51ed5468856d36f34af56ce118fa6518cc8f7d0 Mon Sep 17 00:00:00 2001 From: reneSchm <49305466+reneSchm@users.noreply.github.com> Date: Tue, 26 Aug 2025 14:19:52 +0200 Subject: [PATCH 10/17] no isolation --- .github/actions/build-py/action.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/actions/build-py/action.yml b/.github/actions/build-py/action.yml index f2dc707410..467cae043f 100644 --- a/.github/actions/build-py/action.yml +++ b/.github/actions/build-py/action.yml @@ -20,9 +20,9 @@ runs: run: | cd pycode/memilio-${{ inputs.package }}/ /opt/python/cp38-cp38/bin/python -m pip install scikit-build - /opt/python/cp38-cp38/bin/python -m build --installer pip + /opt/python/cp38-cp38/bin/python -m build --no-isolation /opt/python/cp311-cp311/bin/python -m pip install scikit-build - /opt/python/cp311-cp311/bin/python -m build --installer pip + /opt/python/cp311-cp311/bin/python -m build --no-isolation # Exclude memilio-generation, because its a pure python package, cmake is only used in the build process to retrieve data from cpp if [[ -f "CMakeLists.txt" ]] && [ "${{ inputs.package }}" != "generation" ]; then # includes native dependencies in the wheel From 99854ed3fbbd3e2135e6108eddb0f6f41c13968b Mon Sep 17 00:00:00 2001 From: reneSchm <49305466+reneSchm@users.noreply.github.com> Date: Tue, 26 Aug 2025 14:34:44 +0200 Subject: [PATCH 11/17] cmake --- .github/actions/build-py/action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/actions/build-py/action.yml b/.github/actions/build-py/action.yml index 467cae043f..c4362b7622 100644 --- a/.github/actions/build-py/action.yml +++ b/.github/actions/build-py/action.yml @@ -9,7 +9,7 @@ runs: steps: - name: Install dependencies shell: bash - run: yum install ninja-build -qy + run: yum install ninja-build cmake -qy - name: Make artifact dir shell: bash run: | From de23868a1c6da39275ed1b413e65701d607e1ac4 Mon Sep 17 00:00:00 2001 From: reneSchm <49305466+reneSchm@users.noreply.github.com> Date: Tue, 26 Aug 2025 14:40:27 +0200 Subject: [PATCH 12/17] remove cmake dependency listing --- pycode/memilio-generation/setup.py | 2 +- pycode/memilio-simulation/setup.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pycode/memilio-generation/setup.py b/pycode/memilio-generation/setup.py index 9237035c47..4166b570a3 100644 --- a/pycode/memilio-generation/setup.py +++ b/pycode/memilio-generation/setup.py @@ -25,7 +25,7 @@ description='Part of MEmilio project, automatic generation of model specific python bindings.', packages=find_packages( where=os.path.dirname(os.path.abspath(__file__))), - setup_requires=['cmake'], + # setup_requires=['cmake'], install_requires=['libclang==18.1.1', 'dataclasses', 'dataclasses_json', 'graphviz', 'importlib-resources>=1.1.0; python_version < \'3.9\''], extras_require={'dev': []}, diff --git a/pycode/memilio-simulation/setup.py b/pycode/memilio-simulation/setup.py index b4038394bf..aff8998991 100644 --- a/pycode/memilio-simulation/setup.py +++ b/pycode/memilio-simulation/setup.py @@ -21,7 +21,7 @@ url='https://github.com/SciCompMod/memilio', description='Part of MEmilio project, python bindings to the C++ libraries that contain the models and simulations.', packages=find_packages(where=os.path.dirname(os.path.abspath(__file__))), - setup_requires=['cmake'], + # setup_requires=['cmake'], # need shared libs so there is one shared log level cmake_args=['-DMEMILIO_BUILD_SHARED_LIBS:BOOL=ON'], install_requires=[ From c9d3d78368892fa31b9e616c132063e6125e6127 Mon Sep 17 00:00:00 2001 From: reneSchm <49305466+reneSchm@users.noreply.github.com> Date: Tue, 26 Aug 2025 14:42:22 +0200 Subject: [PATCH 13/17] git? --- .github/actions/build-py/action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/actions/build-py/action.yml b/.github/actions/build-py/action.yml index c4362b7622..f40e88a6ff 100644 --- a/.github/actions/build-py/action.yml +++ b/.github/actions/build-py/action.yml @@ -9,7 +9,7 @@ runs: steps: - name: Install dependencies shell: bash - run: yum install ninja-build cmake -qy + run: yum install ninja-build cmake git -qy - name: Make artifact dir shell: bash run: | From f03d720d38b571fca83615ef376053a7d4573751 Mon Sep 17 00:00:00 2001 From: reneSchm <49305466+reneSchm@users.noreply.github.com> Date: Tue, 26 Aug 2025 14:47:44 +0200 Subject: [PATCH 14/17] dubious ownership --- .github/actions/build-py/action.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/actions/build-py/action.yml b/.github/actions/build-py/action.yml index f40e88a6ff..6291d00e51 100644 --- a/.github/actions/build-py/action.yml +++ b/.github/actions/build-py/action.yml @@ -18,6 +18,7 @@ runs: - name: Build Python Wheels shell: bash run: | + git config --global --add safe.directory $(pwd) # fix to "fatal: detected dubious ownership in repository" cd pycode/memilio-${{ inputs.package }}/ /opt/python/cp38-cp38/bin/python -m pip install scikit-build /opt/python/cp38-cp38/bin/python -m build --no-isolation From 227ed8c1309d8451aceed8ddbcda2487fbb61105 Mon Sep 17 00:00:00 2001 From: HenrZu <69154294+HenrZu@users.noreply.github.com> Date: Wed, 27 Aug 2025 15:00:37 +0200 Subject: [PATCH 15/17] build no SD --- .github/actions/build-py/action.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/actions/build-py/action.yml b/.github/actions/build-py/action.yml index 6291d00e51..a27a381761 100644 --- a/.github/actions/build-py/action.yml +++ b/.github/actions/build-py/action.yml @@ -21,9 +21,9 @@ runs: git config --global --add safe.directory $(pwd) # fix to "fatal: detected dubious ownership in repository" cd pycode/memilio-${{ inputs.package }}/ /opt/python/cp38-cp38/bin/python -m pip install scikit-build - /opt/python/cp38-cp38/bin/python -m build --no-isolation + /opt/python/cp38-cp38/bin/python -m build --no-isolation --wheel /opt/python/cp311-cp311/bin/python -m pip install scikit-build - /opt/python/cp311-cp311/bin/python -m build --no-isolation + /opt/python/cp311-cp311/bin/python -m build --no-isolation --wheel # Exclude memilio-generation, because its a pure python package, cmake is only used in the build process to retrieve data from cpp if [[ -f "CMakeLists.txt" ]] && [ "${{ inputs.package }}" != "generation" ]; then # includes native dependencies in the wheel From a6a35c59a6bb1d171ff6627e5a58d71339e465c3 Mon Sep 17 00:00:00 2001 From: HenrZu <69154294+HenrZu@users.noreply.github.com> Date: Wed, 27 Aug 2025 15:13:50 +0200 Subject: [PATCH 16/17] revert changes --- .github/actions/build-py/action.yml | 3 +- .github/workflows/main.yml | 490 ++++++++++++++-------------- pycode/memilio-generation/setup.py | 2 +- pycode/memilio-simulation/setup.py | 2 +- 4 files changed, 248 insertions(+), 249 deletions(-) diff --git a/.github/actions/build-py/action.yml b/.github/actions/build-py/action.yml index a27a381761..e0a24b22bd 100644 --- a/.github/actions/build-py/action.yml +++ b/.github/actions/build-py/action.yml @@ -9,7 +9,7 @@ runs: steps: - name: Install dependencies shell: bash - run: yum install ninja-build cmake git -qy + run: yum install ninja-build -qy - name: Make artifact dir shell: bash run: | @@ -18,7 +18,6 @@ runs: - name: Build Python Wheels shell: bash run: | - git config --global --add safe.directory $(pwd) # fix to "fatal: detected dubious ownership in repository" cd pycode/memilio-${{ inputs.package }}/ /opt/python/cp38-cp38/bin/python -m pip install scikit-build /opt/python/cp38-cp38/bin/python -m build --no-isolation --wheel diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 6c02ac9616..9b0c6505ea 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -22,240 +22,240 @@ concurrency: cancel-in-progress: true jobs: - # pre-commit: - # runs-on: ubuntu-latest - # steps: - # - uses: actions/checkout@v4 - # - uses: actions/setup-python@v5 - # with: - # python-version: 3.11 - # - uses: pre-commit/action@v3.0.1 + pre-commit: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 + with: + python-version: 3.11 + - uses: pre-commit/action@v3.0.1 - # build-cpp-gcc_clang: - # if: github.event.pull_request.draft == false - # strategy: - # matrix: - # compiler: ["gcc", "clang"] - # config: ["Debug", "Release"] - # version: ["latest", "min"] - # include: - # - version: "latest" - # os: "ubuntu-latest" - # - version: "min" - # os: "ubuntu-22.04" - # runs-on: ${{ matrix.os }} - # steps: - # - uses: actions/checkout@v4 - # - uses: ./.github/actions/linux-build - # with: - # compiler: ${{ matrix.compiler }} - # config: ${{ matrix.config }} - # version: ${{ matrix.version }} - # coverage: ${{ (matrix.compiler == 'gcc' && matrix.config == 'Debug' && matrix.version == 'latest') && 'ON' || 'OFF' }} # `c && t || f` is (usually) equivalent to `c ? t : f` - # sanitizers: ${{ (matrix.compiler == 'gcc' && matrix.config == 'Debug' && matrix.version == 'latest') && 'ON' || 'OFF' }} + build-cpp-gcc_clang: + if: github.event.pull_request.draft == false + strategy: + matrix: + compiler: ["gcc", "clang"] + config: ["Debug", "Release"] + version: ["latest", "min"] + include: + - version: "latest" + os: "ubuntu-latest" + - version: "min" + os: "ubuntu-22.04" + runs-on: ${{ matrix.os }} + steps: + - uses: actions/checkout@v4 + - uses: ./.github/actions/linux-build + with: + compiler: ${{ matrix.compiler }} + config: ${{ matrix.config }} + version: ${{ matrix.version }} + coverage: ${{ (matrix.compiler == 'gcc' && matrix.config == 'Debug' && matrix.version == 'latest') && 'ON' || 'OFF' }} # `c && t || f` is (usually) equivalent to `c ? t : f` + sanitizers: ${{ (matrix.compiler == 'gcc' && matrix.config == 'Debug' && matrix.version == 'latest') && 'ON' || 'OFF' }} - # build-cpp-gcc-no-optional-deps: - # if: github.event.pull_request.draft == false - # runs-on: ubuntu-latest - # steps: - # - uses: actions/checkout@v4 - # - uses: ./.github/actions/linux-build - # with: - # compiler: gcc - # version: latest - # config: Release - # optional-dependencies: OFF + build-cpp-gcc-no-optional-deps: + if: github.event.pull_request.draft == false + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: ./.github/actions/linux-build + with: + compiler: gcc + version: latest + config: Release + optional-dependencies: OFF - # build-cpp-gcc-openmp: - # if: github.event.pull_request.draft == false - # runs-on: ubuntu-latest - # steps: - # - uses: actions/checkout@v4 - # - uses: ./.github/actions/linux-build - # with: - # compiler: gcc - # version: latest - # config: Release - # openmp: ON + build-cpp-gcc-openmp: + if: github.event.pull_request.draft == false + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: ./.github/actions/linux-build + with: + compiler: gcc + version: latest + config: Release + openmp: ON - # build-cpp-msvc: - # if: github.event.pull_request.draft == false - # strategy: - # matrix: - # config: ["Debug", "Release"] - # version: ["latest", "min"] - # include: - # - version: "latest" - # os: "windows-2025" - # - version: "min" - # os: "windows-2022" - # runs-on: ${{ matrix.os }} - # steps: - # - uses: actions/checkout@v4 - # - uses: ./.github/actions/windows-build - # with: - # config: ${{ matrix.config }} - # version: ${{ matrix.version }} + build-cpp-msvc: + if: github.event.pull_request.draft == false + strategy: + matrix: + config: ["Debug", "Release"] + version: ["latest", "min"] + include: + - version: "latest" + os: "windows-2025" + - version: "min" + os: "windows-2022" + runs-on: ${{ matrix.os }} + steps: + - uses: actions/checkout@v4 + - uses: ./.github/actions/windows-build + with: + config: ${{ matrix.config }} + version: ${{ matrix.version }} - # build-cpp-msvc-no-optional-deps: - # if: github.event.pull_request.draft == false - # runs-on: windows-2025 - # steps: - # - uses: actions/checkout@v4 - # - uses: ./.github/actions/windows-build - # with: - # config: Release - # version: latest - # optional-dependencies: OFF + build-cpp-msvc-no-optional-deps: + if: github.event.pull_request.draft == false + runs-on: windows-2025 + steps: + - uses: actions/checkout@v4 + - uses: ./.github/actions/windows-build + with: + config: Release + version: latest + optional-dependencies: OFF - # test-cpp-gcc_clang: - # if: github.event.pull_request.draft == false - # needs: build-cpp-gcc_clang - # strategy: - # matrix: - # compiler: ["gcc", "clang"] - # config: ["Debug", "Release"] - # version: ["latest", "min"] - # include: - # - version: "latest" - # os: "ubuntu-latest" - # - version: "min" - # os: "ubuntu-22.04" - # runs-on: ${{ matrix.os }} - # steps: - # - uses: actions/checkout@v4 - # - uses: ./.github/actions/linux-test - # with: - # artifact-pattern: ${{ matrix.compiler }}-${{ matrix.version }}-${{ matrix.config }} - # coverage: ${{ (matrix.compiler == 'gcc' && matrix.version == 'latest' && matrix.config == 'Debug') && 'ON' || 'OFF' }} + test-cpp-gcc_clang: + if: github.event.pull_request.draft == false + needs: build-cpp-gcc_clang + strategy: + matrix: + compiler: ["gcc", "clang"] + config: ["Debug", "Release"] + version: ["latest", "min"] + include: + - version: "latest" + os: "ubuntu-latest" + - version: "min" + os: "ubuntu-22.04" + runs-on: ${{ matrix.os }} + steps: + - uses: actions/checkout@v4 + - uses: ./.github/actions/linux-test + with: + artifact-pattern: ${{ matrix.compiler }}-${{ matrix.version }}-${{ matrix.config }} + coverage: ${{ (matrix.compiler == 'gcc' && matrix.version == 'latest' && matrix.config == 'Debug') && 'ON' || 'OFF' }} - # test-cpp-gcc-sbml: - # if: github.event.pull_request.draft == false - # needs: build-cpp-gcc_clang - # runs-on: ubuntu-latest - # steps: - # - uses: actions/checkout@v4 - # - uses: ./.github/actions/sbml-test + test-cpp-gcc-sbml: + if: github.event.pull_request.draft == false + needs: build-cpp-gcc_clang + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: ./.github/actions/sbml-test - # merge-test-artifacts: - # needs: [test-cpp-gcc_clang, test-cpp-msvc, test-py-surrogatemodel] - # runs-on: ubuntu-latest - # steps: - # - name: merge-coverage-artifacts - # uses: actions/upload-artifact/merge@v4 - # with: - # name: test-cpp-coverage-reports - # pattern: test-cpp-coverage-reports-* - # - name: merge-linux-artifacts - # uses: actions/upload-artifact/merge@v4 - # with: - # name: test-cpp-linux-report - # pattern: test-cpp-linux-report-* - # - name: merge-windows-artifacts - # uses: actions/upload-artifact/merge@v4 - # with: - # name: test-cpp-win-report - # pattern: test-cpp-win-report-* - # - name: merge python reports - # uses: actions/upload-artifact/merge@v4 - # with: - # name: test-py-coverage-reports-surrogatemodel - # pattern: test-py-coverage-reports-surrogatemodel-* + merge-test-artifacts: + needs: [test-cpp-gcc_clang, test-cpp-msvc, test-py-surrogatemodel] + runs-on: ubuntu-latest + steps: + - name: merge-coverage-artifacts + uses: actions/upload-artifact/merge@v4 + with: + name: test-cpp-coverage-reports + pattern: test-cpp-coverage-reports-* + - name: merge-linux-artifacts + uses: actions/upload-artifact/merge@v4 + with: + name: test-cpp-linux-report + pattern: test-cpp-linux-report-* + - name: merge-windows-artifacts + uses: actions/upload-artifact/merge@v4 + with: + name: test-cpp-win-report + pattern: test-cpp-win-report-* + - name: merge python reports + uses: actions/upload-artifact/merge@v4 + with: + name: test-py-coverage-reports-surrogatemodel + pattern: test-py-coverage-reports-surrogatemodel-* - # test-cpp-gcc-no-optional-deps: - # if: github.event.pull_request.draft == false - # needs: build-cpp-gcc-no-optional-deps - # runs-on: ubuntu-latest - # steps: - # - uses: actions/checkout@v4 - # - uses: ./.github/actions/linux-test - # with: - # artifact-pattern: gcc-latest-Release - # optional-deps: OFF + test-cpp-gcc-no-optional-deps: + if: github.event.pull_request.draft == false + needs: build-cpp-gcc-no-optional-deps + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: ./.github/actions/linux-test + with: + artifact-pattern: gcc-latest-Release + optional-deps: OFF - # test-cpp-gcc-openmp: - # if: github.event.pull_request.draft == false - # needs: build-cpp-gcc-openmp - # runs-on: ubuntu-latest - # timeout-minutes: 30 - # env: - # OMP_NUM_THREADS: 4 - # steps: - # - uses: actions/checkout@v4 - # - uses: ./.github/actions/linux-test - # with: - # artifact-pattern: gcc-latest-Release - # num-repeat: 10 - # openmp: ON + test-cpp-gcc-openmp: + if: github.event.pull_request.draft == false + needs: build-cpp-gcc-openmp + runs-on: ubuntu-latest + timeout-minutes: 30 + env: + OMP_NUM_THREADS: 4 + steps: + - uses: actions/checkout@v4 + - uses: ./.github/actions/linux-test + with: + artifact-pattern: gcc-latest-Release + num-repeat: 10 + openmp: ON - # test-cpp-msvc: - # if: github.event.pull_request.draft == false - # needs: build-cpp-msvc - # strategy: - # matrix: - # config: ["Debug", "Release"] - # version: ["latest", "min"] - # include: - # - version: "latest" - # os: "windows-2025" - # - version: "min" - # os: "windows-2022" - # runs-on: ${{ matrix.os }} - # steps: - # - uses: actions/checkout@v4 - # - uses: ./.github/actions/windows-test - # with: - # artifact-pattern: msvc-${{ matrix.version }}-${{ matrix.config }} + test-cpp-msvc: + if: github.event.pull_request.draft == false + needs: build-cpp-msvc + strategy: + matrix: + config: ["Debug", "Release"] + version: ["latest", "min"] + include: + - version: "latest" + os: "windows-2025" + - version: "min" + os: "windows-2022" + runs-on: ${{ matrix.os }} + steps: + - uses: actions/checkout@v4 + - uses: ./.github/actions/windows-test + with: + artifact-pattern: msvc-${{ matrix.version }}-${{ matrix.config }} - # test-cpp-msvc-no-optional-deps: - # if: github.event.pull_request.draft == false - # needs: build-cpp-msvc-no-optional-deps - # runs-on: windows-2025 - # steps: - # - uses: actions/checkout@v4 - # - uses: ./.github/actions/windows-test - # with: - # artifact-pattern: msvc-latest-Release - # optional-deps: OFF + test-cpp-msvc-no-optional-deps: + if: github.event.pull_request.draft == false + needs: build-cpp-msvc-no-optional-deps + runs-on: windows-2025 + steps: + - uses: actions/checkout@v4 + - uses: ./.github/actions/windows-test + with: + artifact-pattern: msvc-latest-Release + optional-deps: OFF - # run_examples-cpp-gcc_clang: - # if: github.event.pull_request.draft == false - # needs: build-cpp-gcc_clang - # strategy: - # matrix: - # compiler: ["gcc", "clang"] - # config: ["Debug", "Release"] - # version: ["latest", "min"] - # include: - # - version: "latest" - # os: "ubuntu-latest" - # - version: "min" - # os: "ubuntu-22.04" - # runs-on: ${{ matrix.os }} - # steps: - # - uses: actions/checkout@v4 - # - uses: ./.github/actions/linux-run_examples - # with: - # build-artifact: build-cpp-linux-${{ matrix.compiler }}-${{ matrix.version }}-${{ matrix.config }} + run_examples-cpp-gcc_clang: + if: github.event.pull_request.draft == false + needs: build-cpp-gcc_clang + strategy: + matrix: + compiler: ["gcc", "clang"] + config: ["Debug", "Release"] + version: ["latest", "min"] + include: + - version: "latest" + os: "ubuntu-latest" + - version: "min" + os: "ubuntu-22.04" + runs-on: ${{ matrix.os }} + steps: + - uses: actions/checkout@v4 + - uses: ./.github/actions/linux-run_examples + with: + build-artifact: build-cpp-linux-${{ matrix.compiler }}-${{ matrix.version }}-${{ matrix.config }} - # run_examples-cpp-msvc: - # if: github.event.pull_request.draft == false - # needs: build-cpp-msvc - # strategy: - # matrix: - # config: ["Debug", "Release"] - # version: ["latest", "min"] - # include: - # - version: "latest" - # os: "windows-2025" - # - version: "min" - # os: "windows-2022" - # runs-on: ${{ matrix.os }} - # steps: - # - uses: actions/checkout@v4 - # - uses: ./.github/actions/windows-run_examples - # with: - # build-artifact: build-cpp-windows-msvc-${{ matrix.version }}-${{ matrix.config }} + run_examples-cpp-msvc: + if: github.event.pull_request.draft == false + needs: build-cpp-msvc + strategy: + matrix: + config: ["Debug", "Release"] + version: ["latest", "min"] + include: + - version: "latest" + os: "windows-2025" + - version: "min" + os: "windows-2022" + runs-on: ${{ matrix.os }} + steps: + - uses: actions/checkout@v4 + - uses: ./.github/actions/windows-run_examples + with: + build-artifact: build-cpp-windows-msvc-${{ matrix.version }}-${{ matrix.config }} build-py-generation: if: github.event.pull_request.draft == false @@ -328,28 +328,28 @@ jobs: package: surrogatemodel coverage: ON - # codecov: - # if: github.event.pull_request.draft == false - # needs: merge-test-artifacts - # runs-on: ubuntu-latest - # steps: - # - uses: actions/checkout@v4 - # - name: Install dependencies - # run: | - # sudo apt-get -qq update - # sudo apt-get -qq -y install git curl - # - name: Download python coverage report - # uses: actions/download-artifact@v4 - # with: - # name: test-py-coverage-reports-surrogatemodel - # - name: Download cpp coverage report - # uses: actions/download-artifact@v4 - # with: - # name: test-cpp-coverage-reports - # - name: Deploy to codecov.io - # uses: codecov/codecov-action@v3 - # with: - # token: ${{ secrets.CODECOV_TOKEN }} - # directory: ./coverage_python - # files: ./coverage_python/**,./coverage.info - # verbose: true + codecov: + if: github.event.pull_request.draft == false + needs: merge-test-artifacts + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Install dependencies + run: | + sudo apt-get -qq update + sudo apt-get -qq -y install git curl + - name: Download python coverage report + uses: actions/download-artifact@v4 + with: + name: test-py-coverage-reports-surrogatemodel + - name: Download cpp coverage report + uses: actions/download-artifact@v4 + with: + name: test-cpp-coverage-reports + - name: Deploy to codecov.io + uses: codecov/codecov-action@v3 + with: + token: ${{ secrets.CODECOV_TOKEN }} + directory: ./coverage_python + files: ./coverage_python/**,./coverage.info + verbose: true diff --git a/pycode/memilio-generation/setup.py b/pycode/memilio-generation/setup.py index 4166b570a3..9237035c47 100644 --- a/pycode/memilio-generation/setup.py +++ b/pycode/memilio-generation/setup.py @@ -25,7 +25,7 @@ description='Part of MEmilio project, automatic generation of model specific python bindings.', packages=find_packages( where=os.path.dirname(os.path.abspath(__file__))), - # setup_requires=['cmake'], + setup_requires=['cmake'], install_requires=['libclang==18.1.1', 'dataclasses', 'dataclasses_json', 'graphviz', 'importlib-resources>=1.1.0; python_version < \'3.9\''], extras_require={'dev': []}, diff --git a/pycode/memilio-simulation/setup.py b/pycode/memilio-simulation/setup.py index aff8998991..b4038394bf 100644 --- a/pycode/memilio-simulation/setup.py +++ b/pycode/memilio-simulation/setup.py @@ -21,7 +21,7 @@ url='https://github.com/SciCompMod/memilio', description='Part of MEmilio project, python bindings to the C++ libraries that contain the models and simulations.', packages=find_packages(where=os.path.dirname(os.path.abspath(__file__))), - # setup_requires=['cmake'], + setup_requires=['cmake'], # need shared libs so there is one shared log level cmake_args=['-DMEMILIO_BUILD_SHARED_LIBS:BOOL=ON'], install_requires=[ From 341c4424b9b0d2988ab57df917b037385be59352 Mon Sep 17 00:00:00 2001 From: HenrZu <69154294+HenrZu@users.noreply.github.com> Date: Wed, 27 Aug 2025 15:17:21 +0200 Subject: [PATCH 17/17] cmake --- .github/actions/build-py/action.yml | 2 +- pycode/memilio-generation/setup.py | 1 - pycode/memilio-simulation/setup.py | 1 - 3 files changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/actions/build-py/action.yml b/.github/actions/build-py/action.yml index e0a24b22bd..2cb89fa75d 100644 --- a/.github/actions/build-py/action.yml +++ b/.github/actions/build-py/action.yml @@ -9,7 +9,7 @@ runs: steps: - name: Install dependencies shell: bash - run: yum install ninja-build -qy + run: yum install ninja-build cmake git -qy - name: Make artifact dir shell: bash run: | diff --git a/pycode/memilio-generation/setup.py b/pycode/memilio-generation/setup.py index 9237035c47..2d3370d80e 100644 --- a/pycode/memilio-generation/setup.py +++ b/pycode/memilio-generation/setup.py @@ -25,7 +25,6 @@ description='Part of MEmilio project, automatic generation of model specific python bindings.', packages=find_packages( where=os.path.dirname(os.path.abspath(__file__))), - setup_requires=['cmake'], install_requires=['libclang==18.1.1', 'dataclasses', 'dataclasses_json', 'graphviz', 'importlib-resources>=1.1.0; python_version < \'3.9\''], extras_require={'dev': []}, diff --git a/pycode/memilio-simulation/setup.py b/pycode/memilio-simulation/setup.py index b4038394bf..037a93df8e 100644 --- a/pycode/memilio-simulation/setup.py +++ b/pycode/memilio-simulation/setup.py @@ -21,7 +21,6 @@ url='https://github.com/SciCompMod/memilio', description='Part of MEmilio project, python bindings to the C++ libraries that contain the models and simulations.', packages=find_packages(where=os.path.dirname(os.path.abspath(__file__))), - setup_requires=['cmake'], # need shared libs so there is one shared log level cmake_args=['-DMEMILIO_BUILD_SHARED_LIBS:BOOL=ON'], install_requires=[