-
-
Notifications
You must be signed in to change notification settings - Fork 18.5k
MultiIndex union/intersection with non-object other #32646
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
Conversation
[self._values, other._ndarray_values], sort=sort | ||
) | ||
if not is_object_dtype(other.dtype): | ||
raise NotImplementedError( |
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.
is this hit in any tests?
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.
no, can add one
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.
can you add one
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.
added+green (though no azure)
gentle ping; we're on the verge of being rid of _ndarray_values |
thanks |
black pandas
git diff upstream/master -u -- "*.py" | flake8 --diff
ATM if we call MultiIndex.union with e.g. a Float64Index, we get
ValueError: Buffer dtype mismatch, expected 'Python object' but got 'double'
fromlib.fast_unique_multiple
. This PR changes that to raise NotImplementedError with a reasonable message, but we could alternatively returnself.to_flat_index().union(other)
I prefer making the user do to_flat_index on their own because this seems like something that would often be reached by accident.