-
-
Notifications
You must be signed in to change notification settings - Fork 18.1k
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
BUG: inconsistency between frame.any/all with dt64 vs dt64tz #38723
BUG: inconsistency between frame.any/all with dt64 vs dt64tz #38723
Conversation
pandas/core/arrays/datetimelike.py
Outdated
# Reductions | ||
|
||
def any(self, *, axis: Optional[int] = None, skipna: bool = True): | ||
# GH#33478 |
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.
Is there a reason why this isn't GH 38723
?
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.
LGTM just one question
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.
What is the inconsistency this is fixing? (how is it behaving differently?)
|
Thanks for that example, that helps ;) That's indeed certainly an inconsistency to fix. But quickly checking, this actually seems to have worked fine before, so might be a regression? (and thus should potentially target this for 1.2.1) |
doc/source/whatsnew/v1.3.0.rst
Outdated
@@ -190,6 +190,7 @@ Datetimelike | |||
- Bug in :class:`DataFrame` and :class:`Series` constructors sometimes dropping nanoseconds from :class:`Timestamp` (resp. :class:`Timedelta`) ``data``, with ``dtype=datetime64[ns]`` (resp. ``timedelta64[ns]``) (:issue:`38032`) | |||
- Bug in :meth:`DataFrame.first` and :meth:`Series.first` returning two months for offset one month when first day is last calendar day (:issue:`29623`) | |||
- Bug in constructing a :class:`DataFrame` or :class:`Series` with mismatched ``datetime64`` data and ``timedelta64`` dtype, or vice-versa, failing to raise ``TypeError`` (:issue:`38575`) | |||
- Bug in :meth:`DataFrame.any` and :meth:`DataFrame.all` behaving differently for tznaive vs tzaware ``datetime64`` dtypes (:issue:`38723`) |
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.
move to 1.2.1
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.
updated+green
…mpat-dtlike-reductions
…ndas into compat-dtlike-reductions
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.
I suppose this will also enable the any/all methods on Series?
(in which case we should add tests for that)
Co-authored-by: Joris Van den Bossche <jorisvandenbossche@gmail.com>
…mpat-dtlike-reductions
…mpat-dtlike-reductions
@meeseeksdev backport 1.2.x |
…l with dt64 vs dt64tz
Something went wrong ... Please have a look at my logs. |
…4 vs dt64tz (#38807) Co-authored-by: jbrockmendel <jbrockmendel@gmail.com>
black pandas
git diff upstream/master -u -- "*.py" | flake8 --diff