Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for numpy 2 #1114

Merged
merged 5 commits into from
Jan 30, 2025
Merged

Add support for numpy 2 #1114

merged 5 commits into from
Jan 30, 2025

Conversation

AlanPearl
Copy link
Contributor

@AlanPearl AlanPearl commented Jan 27, 2025

This pull request brings halotools up to date with numpy 2 to bring #1084 to a close. Build system now requires numpy>=2, which compiles code compatible with both numpy 1 and 2.

Edit: Might still need to replace oldest-supported-numpy with numpy>=2 here?

* Update numpy version requirements for build and install
* Replace all `int_t` with `int64_t`
* Replace `string_` with `bytes_` and `unicode_` with `str_`
@@ -51,8 +51,8 @@ markers = ["slow", "installation_test"]
requires = ["setuptools>=42.0.0",
"setuptools_scm",
"wheel",
"oldest-supported-numpy",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bsipocz this PR led by @AlanPearl establishes compatibility between halotools and numpy 2.0. However, I'm not sure about this particular line of code because I never really understood what using oldest-supported-numpy did. But this PR fails unless this line is changed to numpy>=2.0.

On a possibly related note, I'm also not sure whether any additional changes need to be made in order to properly use extension-helpers in the right way.

@aphearin
Copy link
Contributor

This PR also implements python>=3.11 and so closes #1111.

@aphearin aphearin merged commit 7b9a333 into astropy:master Jan 30, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants