From 263baac95244bd831fa68f2e0a45fbc735eca9b5 Mon Sep 17 00:00:00 2001 From: zacharyburnett Date: Fri, 31 May 2024 14:33:29 -0400 Subject: [PATCH 1/3] pin `numpy>=2.0.0rc2` in `build-system.requires` --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index cba950f3..1e0c6b3d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ requires = [ "setuptools >=61", "setuptools_scm[toml] >=3.4", "Cython >=0.29.21", - "numpy >=1.18", + "numpy >=2.0.0rc2", ] build-backend = "setuptools.build_meta" From 7893d9144b0516ed44efdb93bc4912d619be2bd4 Mon Sep 17 00:00:00 2001 From: Brett Date: Mon, 3 Jun 2024 08:47:54 -0400 Subject: [PATCH 2/3] rename NPY_NTYPES for numpy 2.0 --- src/stcal/ramp_fitting/src/slope_fitter.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/stcal/ramp_fitting/src/slope_fitter.c b/src/stcal/ramp_fitting/src/slope_fitter.c index f0811e22..1fbd5462 100644 --- a/src/stcal/ramp_fitting/src/slope_fitter.c +++ b/src/stcal/ramp_fitting/src/slope_fitter.c @@ -3486,7 +3486,7 @@ print_npy_types() { printf("NPY_DOUBLE = %d\n",NPY_DOUBLE); printf("NPY_VOID = %d\n",NPY_VOID); - printf("NPY_NTYPES = %d\n",NPY_NTYPES); + printf("NPY_NTYPES_LEGACY = %d\n",NPY_NTYPES_LEGACY); printf("NPY_NOTYPE = %d\n",NPY_NOTYPE); /* NPY_SHORT From b16a9e7674c4f85f3ab247aa9c8e310953ac3c80 Mon Sep 17 00:00:00 2001 From: zacharyburnett Date: Mon, 3 Jun 2024 09:03:07 -0400 Subject: [PATCH 3/3] add change log entry --- CHANGES.rst | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CHANGES.rst b/CHANGES.rst index b13b6886..fc7ab763 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -1,6 +1,11 @@ 1.7.2 (unreleased) ================== +General +------- + +- build with Numpy 2.0 release candidate [#260] + Changes to API --------------