Uh oh!
There was an error while loading. Please reload this page.
Support additional dtypes in resample - #9413
Conversation
Thank you for opening this pull request! It may take us a few days to respond here, so thank you for being patient. |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
max-sixty
commented
Sep 1, 2024
Looks good! Can we add a test? |
pandas.BaseOffset, pandas.Timedelta, datetime.timedelta, and BaseCFTimeOffset are now all supported datatypes for resampling.
1e6cf96 to
36b8a63CompareUh oh!
There was an error while loading. Please reload this page.
9588cf4 to
1ed7c7fCompare9ec6d18 to
769e850CompareUh oh!
There was an error while loading. Please reload this page.
oliverhiggs
commented
Sep 5, 2024
This is failing a test on the bare-minimum environment because of a FutureWarning caused by pandas 2.0.3 using 'S' instead of 's' for an internal frequency string. I noticed there are other FutureWarnings that occur during the test run but don't cause a test failure, why is this? Is it possible to do the same with my test? e.g. This warning does not cause a test failure. |
Uh oh!
There was an error while loading. Please reload this page.
yes we can take it from here. Thanks for your contribution and welcome to Xarray! |
oliverhiggs
commented
Sep 5, 2024
Thanks! And thanks for creating such a welcoming atmosphere for new contributors. |
spencerkclark
left a comment
There was a problem hiding this comment.
@oliverhiggs sorry for the delay—this looks great!
To answer your question about the warning leading to a test failure—a few months ago we made a change to make any new warnings emitted in the test suite errors (#8974). In that PR some code was added to ignore some existing warnings (the MultiIndex warning you noted being one of them).
We've dealt with the frequency string deprecation warning in the past in the context of old pandas versions (#8627); I made a suggestion which I think may resolve it.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Co-authored-by: Spencer Clark <spencerkclark@gmail.com>
Uh oh!
There was an error while loading. Please reload this page.

pandas.BaseOffset, pandas.Timedelta, datetime.timedelta, and BaseCFTimeOffset are now all supported datatypes for resampling.
Closes#9408