Skip to content

Commit 36ed5ec

Browse files
committed
Minor fixes to pass a couple build tests.
1 parent 74fd8b5 commit 36ed5ec

File tree

2 files changed

+9
-4
lines changed

2 files changed

+9
-4
lines changed

doc/source/whatsnew/v3.0.0.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1266,6 +1266,7 @@ Other
12661266
- Fixed bug in the :meth:`Series.rank` with object dtype and extremely small float values (:issue:`62036`)
12671267
- Fixed bug where the :class:`DataFrame` constructor misclassified array-like objects with a ``.name`` attribute as :class:`Series` or :class:`Index` (:issue:`61443`)
12681268
- Fixed regression in :meth:`DataFrame.from_records` not initializing subclasses properly (:issue:`57008`)
1269+
12691270
.. ***DO NOT USE THIS SECTION***
12701271
12711272
-

pandas/core/frame.py

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9109,13 +9109,17 @@ def combine(
91099109

91109110
new_columns_out = self.columns.union(other_columns, sort=False)
91119111
# Deduplicate column names if necessary
9112-
self_columns = Index(dedup_names(self_columns, False), dtype=self_columns.dtype)
9112+
self_columns = Index(
9113+
dedup_names(list(self_columns), False), dtype=self_columns.dtype
9114+
)
91139115
other_columns = Index(
9114-
dedup_names(other_columns, False), dtype=other_columns.dtype
9116+
dedup_names(list(other_columns), False), dtype=other_columns.dtype
9117+
)
9118+
this.columns = Index(
9119+
dedup_names(list(this.columns), False), dtype=this.columns.dtype
91159120
)
9116-
this.columns = Index(dedup_names(this.columns, False), dtype=this.columns.dtype)
91179121
other.columns = Index(
9118-
dedup_names(other.columns, False), dtype=other.columns.dtype
9122+
dedup_names(list(other.columns), False), dtype=other.columns.dtype
91199123
)
91209124

91219125
# preserve column order

0 commit comments

Comments
 (0)