TST: Fix devdeps#15363
Conversation
because matplotlib was pulling in contourpy that pinned numpy<2. TST: Fix mpldev not pulling in from Scientific Python nightlies. TST: Remove asdf-astropy dev testing completely because it is downstream now. TST: Add verbose to devdeps to help debugging. TST: Removed redundant extras directive for devdeps. It is always called with test.
as per numpy 2.0
|
Thank you for your contribution to Astropy! 🌌 This checklist is meant to remind the package maintainers who will review this pull request of some common things to look for.
|
|
👋 Thank you for your draft pull request! Do you know that you can use |
mhvk
left a comment
There was a problem hiding this comment.
This looks good! I think separating out mpldev is the way to go for now. But should it perhaps be part of cron rather than regular CI? Most PRs do nothing with matplotlib.
| def tolist(self): | ||
| if self.dtype.kind == "S": | ||
| return np.chararray.decode(self, encoding="utf-8").tolist() | ||
| return np.char.chararray.decode(self, encoding="utf-8").tolist() |
There was a problem hiding this comment.
Wow, that certainly is simpler than I thought. Possibly, eventually np.char will also be deprecated, but we can take it one at a time!
There was a problem hiding this comment.
This may be painful for io.fits 😱
There was a problem hiding this comment.
At least for now it seems np.char continues to exist. I think it is meant to go to a "legacy" grouping (see https://numpy.org/neps/nep-0052-python-api-cleanup.html#cleaning-up-the-submodule-structure). I had missed this, but fortunately @pllim just tested things and realized that it was just np.chararray that is the problem - it will be removed from the main namespace.
There was a problem hiding this comment.
Do you wanna think about future-proofing and remove usage of np.char altogether? 😬
There was a problem hiding this comment.
Maybe. Though I just noticed that there is a current PR over at numpy trying to speed it up by converting some of the code to C. So, maybe best to leave things as they are for now -- especially as we're dealing with so much churn already!
Unfortunately, |
mhvk
left a comment
There was a problem hiding this comment.
I'm not sure how it helps to have regular PRs have failures for it -- while I can see that it is useful to ensure we don't introduce problems for numpy-dev. But really you are the one who knows this best, so happy to approve!
|
The goal of this PR is to kinda do what we have been doing anyway. So if you think mpldev should be in cron, then really it is a separate PR. But let's see if it is even a problem first. It actually completed way faster than numpy-dev job (because the mpldev job does not pull remote data). |
|
OK, makes sense! |
Description
This pull request is to address:
numpy/__init__.pyand main namespace - Part 5 [NEP 52] numpy/numpy#24587I don't think it'll be a clean backport but I do want to backport some of this to v5.3.x to prep for Python 3.12 work.No, wait, never mind. We already pinnednumpy<2in v5.3.x so none of this is relevant.