-
-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Allow subtraction of time dtype columns #20300
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #20300 +/- ##
==========================================
- Coverage 79.60% 79.59% -0.02%
==========================================
Files 1565 1566 +1
Lines 218396 218322 -74
Branches 2477 2465 -12
==========================================
- Hits 173860 173778 -82
- Misses 43970 43975 +5
- Partials 566 569 +3 ☔ View full report in Codecov by Sentry. |
What about the inverse? If we have t2 - t1 = d, how about t1 + d = t2, i.e. time + duration? |
I considered implementing it within this PR but thought it's ultimately another feature. It also needs to be discussed which behavior we want if d > 24h. Should we even allow it? |
I recall a while back during some AnyValue conversion that @stinodego came up with a set of rules regarding what temporal ops are allowed.
|
Closes #19720
Since the documentation specifies the Time dtype as
we can specify the result of a substraction as a duration with nanosecond time unit.