From 7aeb842937a8eb94d38746b7ba07be56aa2112bd Mon Sep 17 00:00:00 2001 From: David Hoese Date: Fri, 12 Apr 2024 10:24:13 -0500 Subject: [PATCH 1/7] Build against numpy 2.0rc1 --- .github/workflows/deploy.yaml | 3 --- pyproject.toml | 3 +-- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/.github/workflows/deploy.yaml b/.github/workflows/deploy.yaml index 812048e..4c3813c 100644 --- a/.github/workflows/deploy.yaml +++ b/.github/workflows/deploy.yaml @@ -64,9 +64,6 @@ jobs: CIBW_SKIP: "cp36-* cp37-* cp38-* pp* *-manylinux_i686 *-musllinux_i686 *-musllinux_aarch64 *-win32" CIBW_ARCHS: "${{ matrix.cibw_archs }}" CIBW_TEST_SKIP: "*_arm64 *_universal2:arm64" - # below only for building against unstable numpy - CIBW_BUILD_FRONTEND: "pip; args: --no-build-isolation" - CIBW_BEFORE_BUILD: "pip install --pre --extra-index-url https://pypi.anaconda.org/scientific-python-nightly-wheels/simple numpy cython setuptools versioneer" - uses: actions/upload-artifact@v4 with: diff --git a/pyproject.toml b/pyproject.toml index 988581c..9012fc2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,8 +1,7 @@ [build-system] requires = [ "wheel", - 'numpy; python_full_version<"3.12.0rc1"', - 'numpy>=1.26.0rc1; python_full_version>="3.12.0rc1"', + "numpy>=2.0.0rc1,<2.3", "setuptools>=42", "versioneer", "Cython>=3.0.0" From 7f06049bb16f21c1f113d18bce929a0980172884 Mon Sep 17 00:00:00 2001 From: David Hoese Date: Fri, 12 Apr 2024 11:01:55 -0500 Subject: [PATCH 2/7] Update unstable CI to use no build isolation --- .github/workflows/ci.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index c992b1f..ba786cf 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -13,7 +13,7 @@ jobs: python-version: ["3.9", "3.11", "3.12"] experimental: [false] include: - - python-version: "3.11" + - python-version: "3.12" os: "ubuntu-latest" experimental: true @@ -50,13 +50,14 @@ jobs: numpy \ pandas; \ python -m pip install \ - --no-deps --upgrade \ + --no-deps --upgrade --pre --no-build-isolation \ git+https://github.com/dask/dask \ git+https://github.com/dask/distributed \ git+https://github.com/Unidata/cftime \ git+https://github.com/mapbox/rasterio \ git+https://github.com/pydata/bottleneck \ git+https://github.com/pydata/xarray; + python -m pip install -e . --no-deps --no-build-isolation; - name: Install trollimage shell: bash -l {0} From 6a4e24b58a8d94620116eed3acbc755d9ae30163 Mon Sep 17 00:00:00 2001 From: David Hoese Date: Fri, 12 Apr 2024 11:06:12 -0500 Subject: [PATCH 3/7] Add versioneer to no build isolation unstable CI environ --- .github/workflows/ci.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index ba786cf..fbb96da 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -43,6 +43,7 @@ jobs: if: matrix.experimental == true shell: bash -l {0} run: | + python -m pip install versioneer; \ python -m pip install \ -f https://pypi.anaconda.org/scientific-python-nightly-wheels/simple/ \ --trusted-host pypi.anaconda.org \ From 2538e57aa785051cbf476dd30e3313036768b9b3 Mon Sep 17 00:00:00 2001 From: David Hoese Date: Fri, 12 Apr 2024 11:14:52 -0500 Subject: [PATCH 4/7] Fix missing noexcept declaration on color convert func --- trollimage/_colorspaces.pyx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/trollimage/_colorspaces.pyx b/trollimage/_colorspaces.pyx index 4f668f0..333e42e 100644 --- a/trollimage/_colorspaces.pyx +++ b/trollimage/_colorspaces.pyx @@ -18,7 +18,7 @@ np.import_array() # bint npy_isnan(np.float32_t x) nogil # Function pointer type to allow for generic high-level functions -ctypedef void (*CONVERT_FUNC)(floating[:] comp1, floating[:] comp2, floating[:] comp3, floating[:, ::1] out) nogil +ctypedef void (*CONVERT_FUNC)(floating[:] comp1, floating[:] comp2, floating[:] comp3, floating[:, ::1] out) noexcept nogil cdef: From facde8632d0ea3afa50f4f2d25224dc7bb451df4 Mon Sep 17 00:00:00 2001 From: David Hoese Date: Mon, 15 Apr 2024 10:32:52 -0500 Subject: [PATCH 5/7] Force uninstall pandas before reinstall in unstable env --- .github/workflows/ci.yaml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index fbb96da..fdd2a77 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -43,20 +43,22 @@ jobs: if: matrix.experimental == true shell: bash -l {0} run: | - python -m pip install versioneer; \ + python -m pip install versioneer pkgconfig setuptools-scm; \ + conda uninstall --force-remove -y numpy pandas scipy xarray; \ python -m pip install \ -f https://pypi.anaconda.org/scientific-python-nightly-wheels/simple/ \ --trusted-host pypi.anaconda.org \ --no-deps --pre --upgrade \ numpy \ - pandas; \ + pandas \ + scipy; \ python -m pip install \ --no-deps --upgrade --pre --no-build-isolation \ git+https://github.com/dask/dask \ git+https://github.com/dask/distributed \ - git+https://github.com/Unidata/cftime \ - git+https://github.com/mapbox/rasterio \ + git+https://github.com/rasterio/rasterio \ git+https://github.com/pydata/bottleneck \ + git+https://github.com/zarr-developers/zarr \ git+https://github.com/pydata/xarray; python -m pip install -e . --no-deps --no-build-isolation; From 8e4a80c8e0d86e9af6243bf6905f093c1cd64893 Mon Sep 17 00:00:00 2001 From: David Hoese Date: Mon, 15 Apr 2024 10:36:51 -0500 Subject: [PATCH 6/7] Remove unnecessary scipy in unstable CI --- .github/workflows/ci.yaml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index fdd2a77..0230dbb 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -44,14 +44,13 @@ jobs: shell: bash -l {0} run: | python -m pip install versioneer pkgconfig setuptools-scm; \ - conda uninstall --force-remove -y numpy pandas scipy xarray; \ + conda uninstall --force-remove -y numpy pandas xarray; \ python -m pip install \ -f https://pypi.anaconda.org/scientific-python-nightly-wheels/simple/ \ --trusted-host pypi.anaconda.org \ --no-deps --pre --upgrade \ numpy \ - pandas \ - scipy; \ + pandas; \ python -m pip install \ --no-deps --upgrade --pre --no-build-isolation \ git+https://github.com/dask/dask \ From c77b83021d609fa1a6887a53a41a9c40cd25a1d3 Mon Sep 17 00:00:00 2001 From: David Hoese Date: Mon, 15 Apr 2024 10:48:20 -0500 Subject: [PATCH 7/7] Install pyresample and pykdtree from unstable source in CI --- .github/workflows/ci.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 0230dbb..ad7647d 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -44,7 +44,7 @@ jobs: shell: bash -l {0} run: | python -m pip install versioneer pkgconfig setuptools-scm; \ - conda uninstall --force-remove -y numpy pandas xarray; \ + conda uninstall --force-remove -y numpy pandas xarray pyresample pykdtree; \ python -m pip install \ -f https://pypi.anaconda.org/scientific-python-nightly-wheels/simple/ \ --trusted-host pypi.anaconda.org \ @@ -53,6 +53,8 @@ jobs: pandas; \ python -m pip install \ --no-deps --upgrade --pre --no-build-isolation \ + git+https://github.com/storpipfugl/pykdtree \ + git+https://github.com/pytroll/pyresample \ git+https://github.com/dask/dask \ git+https://github.com/dask/distributed \ git+https://github.com/rasterio/rasterio \