Skip to content

Expose pandas.Timestamp in bodo.pandas#922

Merged
scott-routledge2 merged 2 commits intomainfrom
scott/timestamp
Nov 12, 2025
Merged

Expose pandas.Timestamp in bodo.pandas#922
scott-routledge2 merged 2 commits intomainfrom
scott/timestamp

Conversation

@scott-routledge2
Copy link
Contributor

@scott-routledge2 scott-routledge2 commented Nov 11, 2025

Changes included in this PR

Currently, everything not supported in the DataFrame library is wrapped with fallback_wrapper. This creates issues for Timestamp (and potentially other scalar types):

  1. extra warnings for non performance critical scalar ops e.g. Timestamp.day_of_week
  2. Static methods of that object will throw an error e.g. Timestamp.now()

This PR just exposes the actual pandas.Timestamp type to Bodo DataFrames and can be extended to other scalars and types that are not performance critical as well.

Testing strategy

New unit tests added.

User facing changes

pd.Timestamp.now() works.
pd.Timestamp(x) doesn't warn.

Checklist

  • Pipelines passed before requesting review. To run CI you must include [run CI] in your commit message.
  • I am familiar with the Contributing Guide
  • I have installed + ran pre-commit hooks.

@scott-routledge2 scott-routledge2 marked this pull request as ready for review November 11, 2025 20:39
@codecov
Copy link

codecov bot commented Nov 11, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 68.78%. Comparing base (c33fbb5) to head (6e0dba0).
⚠️ Report is 117 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #922      +/-   ##
==========================================
+ Coverage   66.68%   68.78%   +2.10%     
==========================================
  Files         186      195       +9     
  Lines       66795    67560     +765     
  Branches     9507     9594      +87     
==========================================
+ Hits        44543    46472    +1929     
+ Misses      19572    18258    -1314     
- Partials     2680     2830     +150     

Copy link
Collaborator

@DrTodd13 DrTodd13 left a comment

Choose a reason for hiding this comment

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

Awesome simple fix! Thanks.

Copy link
Collaborator

@ehsantn ehsantn left a comment

Choose a reason for hiding this comment

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

@scott-routledge2 scott-routledge2 merged commit 31e0fea into main Nov 12, 2025
29 checks passed
@scott-routledge2 scott-routledge2 deleted the scott/timestamp branch November 12, 2025 14:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants