-
-
Notifications
You must be signed in to change notification settings - Fork 228
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
Fixes for NumPy 2.0 compatiblity #422
Conversation
Hi @WilliamJamieson |
Since NumPy 2.0 is still in development you probably do not want to cache it because you will need to pull the nightly wheel. |
- python-version: 3.9 | ||
numpy-version: "2.0.dev" | ||
- python-version: 3.10 | ||
numpy-version: "2.0.dev" | ||
- python-version: 3.11 | ||
numpy-version: "2.0.dev" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Per NEP 29, NumPy is only supported on Python 3.9+.
LGTM! |
Codecov Report
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. @@ Coverage Diff @@
## dev #422 +/- ##
==========================================
+ Coverage 98.60% 98.63% +0.03%
==========================================
Files 14 14
Lines 3299 3299
==========================================
+ Hits 3253 3254 +1
+ Misses 46 45 -1
|
NumPy 2.0 has removed a couple of type aliases referenced by
deepdiff
as part of NEP 52 in numpy/numpy#24376. Namely,np.float_
, which is an alias ofnp.double
according to the NumPy docs.np.complex_
, which is an alias ofnp.cdouble
according to the NumPy docs.These are blocking my ability to test code using NumPy 2.0 (see spacetelescope/romancal#886).
When I ran the test suite with NumPy 2.0 installed there was one additional deprecation of
np.in1d
in favor ornp.isin
.In any case, the
deepdiff
tests pass locally for me if I install the published dev wheel of NumPy via:pip install --extra-index-url https://pypi.anaconda.org/scientific-python-nightly-wheels/simple "numpy>=0.0.dev0
to override the current
requirements-dev.txt
pin for NumPy. I have not touched the GitHub CI fordeepdiff
in order to run NumPy 2.0 tests at this time, please let me know if/how you would like me to do this if you would like that added.