diff --git a/doc/whats-new.rst b/doc/whats-new.rst index 89bad8f99ad..088ffcc76dc 100644 --- a/doc/whats-new.rst +++ b/doc/whats-new.rst @@ -26,6 +26,9 @@ New Features Breaking changes ~~~~~~~~~~~~~~~~ +- Explicitly forbid appending a :py:class:`~xarray.DataTree` to zarr using :py:meth:`~xarray.DataTree.to_zarr` with ``append_dim``, because the expected behaviour is currently undefined. + (:issue:`9858`, :pull:`10156`) + By `Tom Nicholas `_. Deprecations ~~~~~~~~~~~~ diff --git a/xarray/core/datatree_io.py b/xarray/core/datatree_io.py index 31f5a93dd5e..2a7dd4010f1 100644 --- a/xarray/core/datatree_io.py +++ b/xarray/core/datatree_io.py @@ -103,6 +103,11 @@ def _datatree_to_zarr( "specifying a root group for the tree has not been implemented" ) + if "append_dim" in kwargs: + raise NotImplementedError( + "specifying ``append_dim`` with ``DataTree.to_zarr`` has not been implemented" + ) + if encoding is None: encoding = {} pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy