Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion doc/source/whatsnew/v0.25.2.rst
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ Other
^^^^^

- Compatibility with Python 3.8 in :meth:`DataFrame.query` (:issue:`27261`)
-
- Bug in :meth:`Series.append` where it raised TypeError if tuple of series was passed in 'to_append' param. (:issue:`28410`)

.. _whatsnew_0.252.contributors:

Expand Down
4 changes: 3 additions & 1 deletion pandas/core/series.py
Original file line number Diff line number Diff line change
Expand Up @@ -2729,8 +2729,10 @@ def append(self, to_append, ignore_index=False, verify_integrity=False):
"""
from pandas.core.reshape.concat import concat

if isinstance(to_append, (list, tuple)):
if isinstance(to_append, list):
to_concat = [self] + to_append
elif isinstance(to_append, tuple):
to_concat = [self] + list(to_append)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could just do this on line 2733

else:
to_concat = [self, to_append]
return concat(
Expand Down