[x] This PR addresses an already opened issue (for bug fixes / features)
This PR fixes #xyz
[x] (If applicable) Documentation has been added / updated (for bug fixes / features).
[x] (If applicable) Tests have been added.
[x] This PR does not seem to break the templates.
[x] CHANGES.rst has been updated (with summary of main changes).
[x] Link to issue (:issue:number) and pull request (:pull:number) has been added.
What kind of change does this PR introduce?
Addresses a few FutureWarning I encountered recently:
groupby will change the default to observed=True. I think that our implementation here does not care about observed, even if we use categoricals, but I'm not 100% sure. We could use observed=False to ensure no breaking change.
Changed a few of the old pandas codes that were missed.
Changed pd.unique to np.unique
pd.unique with argument that is not not a Series, Index, ExtensionArray, or np.ndarray is deprecated and will raise in a future version.
intake_esm no longer spams the warning about applymap, so our fix was removed. It still has the "observed=True" spam, however.
Changed an implementation of inplace modifications to a DataFrame.
FutureWarning: A value is trying to be set on a copy of a DataFrame or Series through chained assignment using an inplace method. The behavior will change in pandas 3.0. This inplace method will never work because the intermediate object on which we are setting values always behaves as a copy. For example, when doing 'df[col].method(value, inplace=True)', try using 'df.method({col: value}, inplace=True)' or df[col] = df[col].method(value) instead, to perform the operation inplace on the original object.
Added a temporary fix for the flox spam in the documentation.
Does this PR introduce a breaking change?
To avoid breaking changes, 'Y' and 'M' are still allowed in date_parser, so no.
Pull Request Checklist:
number
) and pull request (:pull:number
) has been added.What kind of change does this PR introduce?
groupby
will change the default toobserved=True
. I think that our implementation here does not care aboutobserved
, even if we use categoricals, but I'm not 100% sure. We could useobserved=False
to ensure no breaking change.pandas
codes that were missed.pd.unique
tonp.unique
pd.unique with argument that is not not a Series, Index, ExtensionArray, or np.ndarray is deprecated and will raise in a future version.
intake_esm
no longer spams the warning aboutapplymap
, so our fix was removed. It still has the "observed=True" spam, however.FutureWarning: A value is trying to be set on a copy of a DataFrame or Series through chained assignment using an inplace method. The behavior will change in pandas 3.0. This inplace method will never work because the intermediate object on which we are setting values always behaves as a copy. For example, when doing 'df[col].method(value, inplace=True)', try using 'df.method({col: value}, inplace=True)' or df[col] = df[col].method(value) instead, to perform the operation inplace on the original object.
flox
spam in the documentation.Does this PR introduce a breaking change?
date_parser
, so no.Other information: