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

fix for numpy 2.0 #349

Merged
merged 1 commit into from
Sep 30, 2024
Merged

fix for numpy 2.0 #349

merged 1 commit into from
Sep 30, 2024

Conversation

johannesulf
Copy link
Contributor

I believe the current version of prospector is incompatible with the new numpy>=2.0 releases since numpy.product has been deprecated. The fix is straightforward: replace numpy.product with numpy.prod. I hope this makes sense. There may be other parts of the code that need to be adjusted, as well.

@bd-j
Copy link
Owner

bd-j commented Sep 30, 2024

Thanks! I did a quick grep and didn't notice any other instances of numpy.product.

@bd-j bd-j merged commit 1f3914e into bd-j:main Sep 30, 2024
4 checks passed
@johannesulf
Copy link
Contributor Author

@bd-j There's also a similar issue with numpy.infty. It needs to be replaced with np.inf.

@bd-j
Copy link
Owner

bd-j commented Oct 1, 2024

ah, thanks, thought I'd caught that one but maybe not everywhere.

@bd-j
Copy link
Owner

bd-j commented Oct 1, 2024

I might be able to add a numpy 2.0 spec to the CI grid.

@johannesulf
Copy link
Contributor Author

Sorry, I was actually playing around with version 1.4. Not sure the issue is still present in main. Sorry for the confusion.

@bd-j
Copy link
Owner

bd-j commented Oct 1, 2024

I think it's fixed on main, except in some parts of the code that are not used and should be removed, but it might be worth a v1.4.1 patch.

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