Skip to content

Commit 90358b3

Browse files
DEPR: generalize join warning for non-Index objects
1 parent 0d254dd commit 90358b3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pandas/core/indexes/base.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4429,9 +4429,9 @@ def join(
44294429
"""
44304430
if not isinstance(other, Index):
44314431
warnings.warn(
4432-
f"Passing a Series to {type(self).__name__}.join is deprecated "
4432+
f"Passing {type(other).__name__} to {type(self).__name__}.join is deprecated "
44334433
"and will raise in a future version. "
4434-
"Pass Index.join(other.index) instead.",
4434+
"Pass an Index instead.",
44354435
Pandas4Warning,
44364436
stacklevel=find_stack_level(),
44374437
)

0 commit comments

Comments
 (0)