-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
BUG: TimedeltaArray+Period, PeriodArray-TimedeltaArray #33883
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
Conversation
Can you explain what this PR is changing? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pls add a whatsnew note.
can you also add an example in the docs (maybe in the timedelta section) |
PeriodIndex - TimedeltaIndex always raises in master, but for some |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm. can you add a whatsnew note.
msg = r"Input has different freq=None from PeriodArray\(freq=Q-DEC\)" | ||
with pytest.raises(IncompatibleFrequency, match=msg): | ||
msg = r"Cannot add or subtract timedelta64\[ns\] dtype from period\[Q-DEC\]" | ||
with pytest.raises(TypeError, match=msg): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
doesn't IncompatibleFrequency inherit from ValueError? so this is technically an api change (ok though)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, this is a change. in the whatsnew i called it a bugfix
thanks |
black pandas
git diff upstream/master -u -- "*.py" | flake8 --diff
motivated by the FIXME comment in test_timedelta64.py