Skip to content
Merged
Changes from 1 commit
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
3 changes: 3 additions & 0 deletions pandas/_libs/tslibs/timedeltas.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -1196,6 +1196,9 @@ class Timedelta(_Timedelta):
msg = textwrap.dedent("""\
Floor division between integer array and Timedelta is
deprecated. Use 'array // timedelta.value' instead.
If you want to obtain epochs from an array of timestamps,
you can rather use
'array - pd.Timestamp("1970-01-01")) // pd.Timedelta('1s')'.
Copy link
Contributor

Choose a reason for hiding this comment

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

maybe double quotes for the Timedelta('1s') just for clarity

Copy link
Member Author

Choose a reason for hiding this comment

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

done

""")
warnings.warn(msg, FutureWarning)
return other // self.value
Expand Down