-
-
Notifications
You must be signed in to change notification settings - Fork 18.3k
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
REGR: concat not sorting columns for mixed column names #47206
Conversation
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.
Thanks @phofl
pandas/core/indexes/api.py
Outdated
@@ -154,7 +155,11 @@ def _get_combined_index( | |||
|
|||
if sort: | |||
try: | |||
index = index.sort_values() | |||
index_sorted = safe_sort(index) |
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.
for clarity, can you rename index_sorted as the return type from safe_sort is an numpy array and not an index.
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.
Good point, done
very nice @phofl |
…xed column names
@meeseeksdev backport 1.4.x |
Could not push to auto-backport-of-pr-47206-on-1.4.x due to error, aborting. |
doc/source/whatsnew/vX.X.X.rst
file if fixing a bug or adding a new feature.The except clause can be removed in 1.5 through handling cases like [1, "a", None] in algorithms, but this would change the behavior a bit so would avoid backporting