Skip to content

Commit

Permalink
remove the deprecated return value of Dataset.update
Browse files Browse the repository at this point in the history
  • Loading branch information
keewis committed Jul 22, 2021
1 parent 28362b5 commit 883f239
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions xarray/core/dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -4157,7 +4157,7 @@ def unstack(
result = result._unstack_once(dim, fill_value)
return result

def update(self, other: "CoercibleMapping") -> "Dataset":
def update(self, other: "CoercibleMapping") -> None:
"""Update this dataset's variables with those from another dataset.
Just like :py:meth:`dict.update` this is a in-place operation.
Expand All @@ -4173,14 +4173,6 @@ def update(self, other: "CoercibleMapping") -> "Dataset":
- mapping {var name: (dimension name, array-like)}
- mapping {var name: (tuple of dimension names, array-like)}
Returns
-------
updated : Dataset
Updated dataset. Note that since the update is in-place this is the input
dataset.
It is deprecated since version 0.17 and scheduled to be removed in 0.19.
Raises
------
ValueError
Expand All @@ -4192,7 +4184,7 @@ def update(self, other: "CoercibleMapping") -> "Dataset":
Dataset.assign
"""
merge_result = dataset_update_method(self, other)
return self._replace(inplace=True, **merge_result._asdict())
self._replace(inplace=True, **merge_result._asdict())

def merge(
self,
Expand Down

0 comments on commit 883f239

Please sign in to comment.