-
-
Notifications
You must be signed in to change notification settings - Fork 1.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
Deprecate inplace methods #1756
Comments
In xarray 0.11.0 several inplace methods are deprecated and will be removed in 0.12.0: pydata/xarray#1756
Hi, At the very least put a big warning sign to the documentation that xarray is still beta and the API is still subject to change. |
@st-bender - sorry to hear this change has caught you by surprise. We're a ways off from 0.12 so you should have time to work in any necessary changes before the feature if fully removed. If you have questions about how to adjust our use these methods, let us know. |
We will probably actually wait longer than until 0.12 for removing this argument, depending on the timing for that release. Unfortunately our API is indeed not entirely stable yet -- that's why the version number is still 0.X, not 1.X. |
Hi, @shoyer In that case I would take it back and vote for a change as soon as possible to stabilize the API. Although xarray is still considered beta, I guess some people already use it productively. @jhamman Thanks for the offer, I think the changes were simple enough. I merely wanted to point out that some more people use(d) that feature. |
Is there a recommendation for merging a dataset without |
The plan is to keep around the update() method, which will always be
inplace. So that's one option.
…On Mon, Mar 25, 2019 at 11:54 AM Nathan Lyons ***@***.***> wrote:
Is there a recommendation for merging a dataset without inplacewhen the
dataset is a subclass of xr.Dataset, other than through composition?
Perhaps lower level functions to merge?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#1756 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ABKS1j_EqfrXRLdXtKgy_wQFVpk27vMgks5vaRtYgaJpZM4QzchO>
.
|
The following methods have an
inplace
argument:DataArray.reset_coords
DataArray.set_index
DataArray.reset_index
DataArray.reorder_levels
Dataset.set_coords
Dataset.reset_coords
Dataset.rename
Dataset.swap_dims
Dataset.set_index
Dataset.reset_index
Dataset.reorder_levels
Dataset.update
Dataset.merge
As proposed in #1755 (comment), let's deprecate all of these at the next major release (v0.11). They add unnecessary complexity to methods and promote confusing about xarray's data model.
Practically, we would change all of the default values to
inplace=None
and issue either aDeprecationWarning
orFutureWarning
(see PEP 565 for more details on that choice).The text was updated successfully, but these errors were encountered: