-
-
Notifications
You must be signed in to change notification settings - Fork 10.9k
BUG: Masked object array of ndarrays attaches mask to masked array value #8906
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
Comments
I think I remember seeing that this is actually intended behaviour in the docs somewhere, but can no longer find where. Anyone else remember this being desirable? |
Found it: 1.10 release notes, introduced in 1a4d943 (#5962)
@mhvk: What was the rationale for not just returning |
Yikes, that PR coming back to bite again: as you will have seen, it was an unintended consequence of what was quite a nice simplification of |
This doesn't sound like something that we should guarantee - we don't guarantee anything else about the properties of the returned value - and it seems like if you're using a masked object array, it's your responsibility to handle Would you be in favor of reverting this in #8905, where the original bug is fixed properly? |
Still present |
Uh oh!
There was an error while loading. Please reload this page.
See below
The culprit is the
# Did we extract a single item?
check innumpy/ma/core.py:3192
.I just don't think we have the information needed to actually know whether we got a single item from
self.data
, which could be of any subclass (?).Maybe the code should become something like:
#8276 (comment) for the lazy
The text was updated successfully, but these errors were encountered: