Skip to content

ENH: Officially support Timedelta arguments in Timestamp.round/floor/ceil (GH#63687)#63773

Open
randolf-scholz wants to merge 6 commits intopandas-dev:mainfrom
randolf-scholz:timestamp_round_timedelta_main
Open

ENH: Officially support Timedelta arguments in Timestamp.round/floor/ceil (GH#63687)#63773
randolf-scholz wants to merge 6 commits intopandas-dev:mainfrom
randolf-scholz:timestamp_round_timedelta_main

Conversation

@randolf-scholz
Copy link
Copy Markdown
Contributor

@randolf-scholz randolf-scholz commented Jan 20, 2026

  • Update type hints to accept str | Timedelta for round/floor/ceil methods

  • Add docstring examples demonstrating Timedelta usage

  • Update parameter documentation to document Timedelta support

  • Add comprehensive test coverage with edge cases

  • Update whatsnew file with enhancement entry

  • closes ENH: Timestamp.round: officially accept Timedelta arguments #63687 (Replace xxxx with the GitHub issue number)

  • Tests added and passed if fixing a bug or adding a new feature

  • All code checks passed.

  • Added type annotations to new arguments/methods/functions.

  • Added an entry in the latest doc/source/whatsnew/vX.X.X.rst file if fixing a bug or adding a new feature.

  • If I used AI to develop this pull request, I prompted it to follow AGENTS.md.

@randolf-scholz randolf-scholz force-pushed the timestamp_round_timedelta_main branch 3 times, most recently from 59832a3 to f76bce2 Compare January 20, 2026 15:48
@github-actions
Copy link
Copy Markdown
Contributor

This pull request is stale because it has been open for thirty days with no activity. Please update and respond to this comment if you're still interested in working on this.

@github-actions github-actions Bot added the Stale label Feb 20, 2026
@jbrockmendel
Copy link
Copy Markdown
Member

I see you have this and #63772 both closing the same issue. Are you pursuing both of them, or can we close one and just focus on the other?

@randolf-scholz
Copy link
Copy Markdown
Contributor Author

randolf-scholz commented Mar 4, 2026

@jbrockmendel The other PR is intentionally marked as draft and builds on top of this one, extending it by the "optional" features of the issue.

But as you can see, the tests are failing and I'd suggest to ignore #63772 it for the time being.

…ceil (GH#63687)

- Update type hints to accept str | Timedelta for round/floor/ceil methods
- Add docstring examples demonstrating Timedelta usage
- Update parameter documentation to document Timedelta support
- Add comprehensive test coverage with edge cases
- Update whatsnew file with enhancement entry
@randolf-scholz randolf-scholz force-pushed the timestamp_round_timedelta_main branch from f76bce2 to 39fb56d Compare March 4, 2026 19:21
@randolf-scholz
Copy link
Copy Markdown
Contributor Author

Did a rebase just now to fix the merge conflict, moving the whatsnew entry into 3.1.0

@randolf-scholz randolf-scholz force-pushed the timestamp_round_timedelta_main branch from cb01638 to 79c0182 Compare March 5, 2026 07:51
Comment thread doc/source/whatsnew/v3.1.0.rst
Comment thread pandas/tests/scalar/timestamp/methods/test_round.py Outdated
@jbrockmendel
Copy link
Copy Markdown
Member

minor comments, otherwise LGTM

@jbrockmendel
Copy link
Copy Markdown
Member

Can you address comments and merge main

@jbrockmendel
Copy link
Copy Markdown
Member

@randolf-scholz this is close to ready, are you planning to finish it?

@randolf-scholz
Copy link
Copy Markdown
Contributor Author

Sorry was really busy with other stuff I'll finish it tomorrow I think.

@randolf-scholz
Copy link
Copy Markdown
Contributor Author

@jbrockmendel I addressed the comments, the remaining CI failure seems unrelated, all recent PRs seem to trip on that check. (e.g. #65332, #65329)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ENH: Timestamp.round: officially accept Timedelta arguments

2 participants