Skip to content

Commit 81b2cfa

Browse files
committed
BUG: fix hash_tuples with length 1 tuples
1 parent 49172dd commit 81b2cfa

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pandas/core/util/hashing.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ def hash_tuples(vals, encoding='utf8', hash_key=None):
146146
from pandas import Categorical, MultiIndex
147147

148148
if not isinstance(vals, ABCMultiIndex):
149-
vals = MultiIndex.from_tuples(vals)
149+
vals = MultiIndex.from_tuples(vals, squeeze=False)
150150

151151
# create a list-of-Categoricals
152152
vals = [Categorical(vals.labels[level],

0 commit comments

Comments
 (0)