-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
BUG: AttributeError: 'DatetimeArray' object has no attribute 'notna' in pandas 2.1.1 #55431
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
Comments
Problem does not occur in pandas-2.2.0.dev0+329.g40f219ccf7 but of course 2.2 isn't available to people. |
It's not occurring on the main development branch as you stated. I'm wondering if a fix needs to be back-ported for this. |
Just so you know, I've been able to pin to pandas As a result I don't need this back-ported, but it would be nice to have. I thought you might want to know about it too. |
Sure but other folks might want to use this without Errors in Pandas 2.1.1. 😎 |
Under the hood, it is
So looking at the code there in And I suppose it is #54884 that actually caused the regression between 2.1.0 and 2.1.1 |
(btw @paulreece, if something is a regression that you could confirm, feel free to add the "next bug fix release" milestone to the issue) |
Will do that next time @jorisvandenbossche . Thanks for clarifying what was happening here! |
Looks like this works on main for me now. Hopefully this is fixed in 2.2 as well. |
@phofl I would like to contribute since the pandas library was very useful for me in the last years. Can you assign this to me? |
Hey akivashor, I am also interested in working on this issue. Do you want to help each other out? |
take |
* Add tests for #55431 * Fix inconsistent pandas namespace usage * Fix inconsistent pandas namespace usage again * Temp disable part of test potentialy due to known bug * Remove unnecessary comments and adjust implementation --------- Co-authored-by: Jason Mok <[email protected]> Co-authored-by: Matthew Roeschke <[email protected]>
* Add tests for pandas-dev#55431 * Fix inconsistent pandas namespace usage * Fix inconsistent pandas namespace usage again * Temp disable part of test potentialy due to known bug * Remove unnecessary comments and adjust implementation --------- Co-authored-by: Jason Mok <[email protected]> Co-authored-by: Matthew Roeschke <[email protected]>
Pandas version checks
I have checked that this issue has not already been reported.
I have confirmed this bug exists on the latest version of pandas.
I have confirmed this bug exists on the main branch of pandas.
Reproducible Example
Issue Description
Note that a potential workaround is to convert the datetime to int and then handle the fallout of that in subsequent code.
Expected Behavior
In pandas 2.1.0 we used to get the binned counts back, such as:
Installed Versions
The text was updated successfully, but these errors were encountered: