-
Notifications
You must be signed in to change notification settings - Fork 655
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
Calling df.loc with multiple arguments results in KeyError #4354
Comments
@naren-ponder do you find the behavior strange? It would be more expected if it would be necessary to explicitly pass the tuple to work with the multi-index, like If this behavior is wrong in pandas itself, maybe we should not repeat it? |
@anmyachev The "expected output" section I indicated above is what happens when you run that snippet of code with pandas. So given that we want to mirror the pandas behavior, I think this is a bug that should be fixed. Perhaps I am misunderstanding your question? |
@naren-ponder In general you are right. But it seemed to me that there was already a precedent when we issued a warning for users that Modin's behavior in such and such a case does not coincide with the behavior of pandas, because the behavior of pandas is erroneous. @modin-project/modin-core do you remember this case? Or am I confusing something? |
The behavior of pandas in this case is not erroneous, I looked at the docs. So we definitely need to fix the case. However, the previous question is still relevant. |
I got the same error, thus upvoting this issue. |
@anmyachev, if Modin behavior does not match the pandas behavior, we issue a warning like this.
|
@alvin-chang An easy workaround for this issue would be to separate out the calls to |
Signed-off-by: Naren Krishna <[email protected]>
This works at version 80c7891. |
System information
modin.__version__
): 0.14.0Resulting Error:
Expected Output (with pandas):
Describe the problem
Calling df.loc with multiple arguments results in Modin believing there are missing labels and therefore raises a KeyError.
Source code / logs
The text was updated successfully, but these errors were encountered: