From 69c7e01e5167a3137c285cb50d1978252bb8bcbf Mon Sep 17 00:00:00 2001 From: Maximilian Roos <5635139+max-sixty@users.noreply.github.com> Date: Mon, 9 Sep 2019 15:17:33 -0400 Subject: [PATCH] Compat and encoding deprecation to 0.14 (#3294) * push the removal of the compat and encoding arguments from Dataset/DataArray back to 0.14 * require dim argument to concat * Update whats-new.rst --- doc/whats-new.rst | 4 ++-- xarray/core/dataarray.py | 2 +- xarray/core/dataset.py | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/doc/whats-new.rst b/doc/whats-new.rst index f5e0f9c467f..d81986cb948 100644 --- a/doc/whats-new.rst +++ b/doc/whats-new.rst @@ -48,8 +48,8 @@ Breaking changes - Any user code that defines custom subclasses of xarray classes must now explicitly define ``__slots__`` itself. Subclasses that don't add any attributes must state so by defining ``__slots__ = ()`` right after the class header. - Omitting ``__slots__`` will now cause a ``FutureWarning`` to be logged, and a hard - crash in a later release. + Omitting ``__slots__`` will now cause a ``FutureWarning`` to be logged, and will raise an + error in a later release. (:issue:`3250`) by `Guido Imperiale `_. - :py:meth:`~Dataset.to_dataset` requires ``name`` to be passed as a kwarg (previously ambiguous diff --git a/xarray/core/dataarray.py b/xarray/core/dataarray.py index a3655e2c4b2..807baddedf9 100644 --- a/xarray/core/dataarray.py +++ b/xarray/core/dataarray.py @@ -315,7 +315,7 @@ def __init__( if encoding is not None: warnings.warn( "The `encoding` argument to `DataArray` is deprecated, and . " - "will be removed in 0.13. " + "will be removed in 0.14. " "Instead, specify the encoding when writing to disk or " "set the `encoding` attribute directly.", FutureWarning, diff --git a/xarray/core/dataset.py b/xarray/core/dataset.py index 1476c1ba646..d6f0da42722 100644 --- a/xarray/core/dataset.py +++ b/xarray/core/dataset.py @@ -489,7 +489,7 @@ def __init__( if compat is not None: warnings.warn( "The `compat` argument to Dataset is deprecated and will be " - "removed in 0.13." + "removed in 0.14." "Instead, use `merge` to control how variables are combined", FutureWarning, stacklevel=2,