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
Ensure the unit is kept in np.median
even if the result is a scalar nan
#14635
Ensure the unit is kept in np.median
even if the result is a scalar nan
#14635
Conversation
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.
|
0944d2c
to
5ac9758
Compare
xref #12146 (comment) |
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.
Nice clean-up. Thanks!
5ac9758
to
512ed21
Compare
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.
LGTM, thanks!
There's a new CI failure in the oldest deps and 32-bit tests that might be real. |
Hmm, yes, definitely looks real. I got frustrated that |
We are going to bump some oldest deps but only for v5.3. So if you end up having to do that, then we cannot backport this. 🤷 |
Same error in 32-bit job, that also uses old deps but not oldest. |
1c60e16
to
3df34b2
Compare
3df34b2
to
9748f58
Compare
Gosh, that took a bit longer than I had hoped - it seems I'm getting rusty. Anyway, all tests pass now, so will merge. Thanks for the quick reviews!! |
This comment was marked as resolved.
This comment was marked as resolved.
…ven if the result is a scalar ``nan``
…ven if the result is a scalar ``nan``
Backport PR #14635: Ensure the unit is kept in ``np.median`` even if the result is a scalar ``nan`` (v5.0.x)
…635-on-v5.2.x Backport PR #14635 on branch v5.2.x (Ensure the unit is kept in ``np.median`` even if the result is a scalar ``nan``)
#14634 reminded me that really #12165 should be fixed in
units
, not worked around instats
.Fixes #12165 and close #14634