From 783d26aa4ed70b3db2641ea2d4c9af300b1c8126 Mon Sep 17 00:00:00 2001 From: Vincent Rouvreau Date: Mon, 10 Feb 2025 15:00:47 +0100 Subject: [PATCH] Try numpy<2 instead of explicit version + uplaod wheel before test --- .github/workflows/pip-build-linux.yml | 10 +++++----- .github/workflows/pip-build-osx.yml | 14 +++++++------- .github/workflows/pip-build-windows.yml | 12 ++++++------ 3 files changed, 18 insertions(+), 18 deletions(-) diff --git a/.github/workflows/pip-build-linux.yml b/.github/workflows/pip-build-linux.yml index 327724dbd..b68716705 100644 --- a/.github/workflows/pip-build-linux.yml +++ b/.github/workflows/pip-build-linux.yml @@ -20,6 +20,11 @@ jobs: cd src/python $PYTHON313/bin/python -m build -n -w auditwheel repair dist/*.whl + - name: Upload linux python wheel + uses: actions/upload-artifact@v4 + with: + name: linux python wheel + path: build_313/src/python/wheelhouse/*.whl # NumPy 2.X is installed and guarantees ABI compatibility, test it with the minimal numpy version for python version - name: Install and test wheel for Python 3.13 run: | @@ -31,8 +36,3 @@ jobs: $PYTHON313/bin/python -m pytest -v src/python/test/test_bottleneck_distance.py $PYTHON313/bin/python -m pytest -v src/python/test/test_cubical_complex.py $PYTHON313/bin/python -m pytest -v src/python/test/test_rips_complex.py - - name: Upload linux python wheel - uses: actions/upload-artifact@v4 - with: - name: linux python wheel - path: build_313/src/python/wheelhouse/*.whl diff --git a/.github/workflows/pip-build-osx.yml b/.github/workflows/pip-build-osx.yml index 928b402ca..2fdf1e263 100644 --- a/.github/workflows/pip-build-osx.yml +++ b/.github/workflows/pip-build-osx.yml @@ -17,7 +17,7 @@ jobs: python-version: ["3.13"] include: - python-version: "3.13" - numpy-version: "1.26.0" + numpy-version: "2.1.0" name: Build wheels for Python ${{ matrix.python-version }} steps: - uses: actions/checkout@v4 @@ -51,10 +51,15 @@ jobs: python -m build -n -w export PATH="$PATH:`python -m site --user-base`/bin" delocate-wheel --require-archs universal2 -v dist/*.whl + - name: Upload OSx python wheel + uses: actions/upload-artifact@v4 + with: + name: osx python wheel + path: build/src/python/dist/*.whl # Test ABI compatibility with numpy 1.X - name: Install and test python wheel run: | - python -m pip install --user numpy~=${{ matrix.numpy-version }} + python -m pip install --user "numpy<2" python -m pip install --user pytest build/src/python/dist/*.whl python -c "import gudhi; print(gudhi.__version__)" python -m pytest -v src/python/test/test_alpha_complex.py @@ -62,8 +67,3 @@ jobs: python -m pytest -v src/python/test/test_bottleneck_distance.py python -m pytest -v src/python/test/test_cubical_complex.py python -m pytest -v src/python/test/test_rips_complex.py - - name: Upload OSx python wheel - uses: actions/upload-artifact@v4 - with: - name: osx python wheel - path: build/src/python/dist/*.whl diff --git a/.github/workflows/pip-build-windows.yml b/.github/workflows/pip-build-windows.yml index 09c5723e3..daa2b0f0a 100644 --- a/.github/workflows/pip-build-windows.yml +++ b/.github/workflows/pip-build-windows.yml @@ -45,13 +45,18 @@ jobs: ls ".\dist\" cd ".\dist\" Get-ChildItem *.whl | ForEach-Object{python -m pip install --user $_.Name} + - name: Upload Windows python wheel + uses: actions/upload-artifact@v4 + with: + name: windows python wheel + path: build/src/python/dist/*.whl # Test ABI compatibility with numpy 1.X - name: Test python wheel run: | $ErrorActionPreference = 'Stop' Get-Location dir - python -m pip install --user numpy~=${{ matrix.numpy-version }} + python -m pip install --user "numpy<2" python -m pip install --user pytest python -c "import gudhi; print(gudhi.__version__)" python -m pytest -v ".\src\python\test\test_alpha_complex.py" @@ -59,8 +64,3 @@ jobs: python -m pytest -v ".\src\python\test\test_bottleneck_distance.py" python -m pytest -v ".\src\python\test\test_cubical_complex.py" python -m pytest -v ".\src\python\test\test_rips_complex.py" - - name: Upload Windows python wheel - uses: actions/upload-artifact@v4 - with: - name: windows python wheel - path: build/src/python/dist/*.whl