diff --git a/doc/whats-new.rst b/doc/whats-new.rst index 6dcbdd1062b..8f7a33ecd8e 100644 --- a/doc/whats-new.rst +++ b/doc/whats-new.rst @@ -6,9 +6,9 @@ What's New ========== -.. _whats-new.2025.10.2: +.. _whats-new.2025.11.0: -v2025.10.2 (unreleased) +v2025.11.0 (unreleased) ----------------------- New Features @@ -17,109 +17,16 @@ New Features - :py:func:`merge` and :py:func:`concat` now support :py:class:`DataTree` objects (:issue:`9790`, :issue:`9778`). By `Stephan Hoyer `_. -- The ``h5netcdf`` engine has support for pseudo ``NETCDF4_CLASSIC`` files, meaning variables and attributes are cast to supported types. Note that the saved files won't be recognized as genuine ``NETCDF4_CLASSIC`` files until ``h5netcdf`` adds support with version 1.7.0. (:issue:`10676`, :pull:`10686`). +- The ``h5netcdf`` engine has support for pseudo ``NETCDF4_CLASSIC`` files, meaning variables and attributes are cast to supported types. Note that the saved files won't be recognized as genuine ``NETCDF4_CLASSIC`` files until ``h5netcdf`` adds support with version 1.7.0 (:issue:`10676`, :pull:`10686`). By `David Huard `_. - Support comparing :py:class:`DataTree` objects with :py:func:`testing.assert_allclose` (:pull:`10887`). By `Justus Magin `_. +- Add support for ``chunks="auto"`` for cftime datasets (:issue:`9834`, :pull:`10527`). + By `Charles Turner `_. Breaking Changes ~~~~~~~~~~~~~~~~ - - -Deprecations -~~~~~~~~~~~~ - - -Bug Fixes -~~~~~~~~~ -- Fix h5netcdf backend for format=None, use same rule as netcdf4 backend (:pull:`10859`). - By `Kai Mühlbauer `_ -- ``netcdf4`` and ``pydap`` backends now use stricter URL detection to avoid incorrectly claiming - remote URLs. The ``pydap`` backend now only claims URLs with explicit DAP protocol indicators - (``dap2://`` or ``dap4://`` schemes, or ``/dap2/`` or ``/dap4/`` in the URL path). This prevents - both backends from claiming remote Zarr stores and other non-DAP URLs without an explicit - ``engine=`` argument. (:pull:`10804`). By `Ian Hunt-Isaak `_. -- Fix indexing with empty arrays for scipy & h5netcdf backends which now resolves to empty slices (:issue:`10867`, :pull:`10870`). - By `Kai Mühlbauer `_ -- Fix error handling issue in ``decode_cf_variables`` when decoding fails - the exception is now re-raised - correctly, with a note added about the variable name that caused the error (:issue:`10873`, :pull:`10886`). - By `Jonas L. Bertelsen `_ - -Performance -~~~~~~~~~~~ - -- Speedup and reduce memory usage of :py:func:`concat`. Magnitude of improvement scales - with size of the concatenation dimension. By `Deepak Cherian `_. - :issue:`10864` :pull:`10866`. - -Documentation -~~~~~~~~~~~~~ - - -Internal Changes -~~~~~~~~~~~~~~~~ - -.. _whats-new.2025.10.1: - -v2025.10.1 (October 7, 2025) ----------------------------- - -This release reverts a breaking change to Xarray's preferred netCDF backend. - -Breaking changes -~~~~~~~~~~~~~~~~ - -- Xarray's default engine for reading/writing netCDF files has been reverted to - prefer netCDF4 over h5netcdf over scipy, which was the default before - v2025.09.1. This change had larger implications for the ecosystem than we - anticipated. We are still considering changing the default in the future, but - will be a bit more careful about the implications. See :issue:`10657` and - linked issues for discussion. The behavior can still be customized, e.g., with - ``xr.set_options(netcdf_engine_order=['h5netcdf', 'netcdf4', 'scipy'])``. - By `Stephan Hoyer `_. - -New features -~~~~~~~~~~~~ - -- Coordinates are ordered to match dims when displaying Xarray objects. (:pull:`10778`). - By `Julia Signell `_. - -Bug fixes -~~~~~~~~~ -- Fix error raised when writing scalar variables to Zarr with ``region={}`` - (:pull:`10796`). - By `Stephan Hoyer `_. - - - -.. _whats-new.2025.09.1: - -v2025.09.1 (September 29, 2025) -------------------------------- - -This release contains improvements to netCDF IO and the -:py:func:`DataTree.from_dict` constructor, as well as a variety of bug fixes. -In particular, the default netCDF backend has switched from netCDF4 to h5netcdf, -which is typically faster. - -Thanks to the 17 contributors to this release: -Claude, Deepak Cherian, Dimitri Papadopoulos Orfanos, Dylan H. Morris, Emmanuel Mathot, Ian Hunt-Isaak, Joren Hammudoglu, Julia Signell, Justus Magin, Maximilian Roos, Nick Hodgskin, Spencer Clark, Stephan Hoyer, Tom Nicholas, gronniger, joseph nowak and pierre-manchon - -New Features -~~~~~~~~~~~~ - -- :py:func:`DataTree.from_dict` now supports passing in ``DataArray`` and nested - dictionary values, and has a ``coords`` argument for specifying coordinates as - ``DataArray`` objects (:pull:`10658`). -- ``engine='netcdf4'`` now supports reading and writing in-memory netCDF files. - All of Xarray's netCDF backends now support in-memory reads and writes - (:pull:`10624`). - By `Stephan Hoyer `_. - -Breaking changes -~~~~~~~~~~~~~~~~ - -- **All xarray operations now preserve attributes by default** (:issue:`3891`, :issue:`2582`). +- All xarray operations now preserve attributes by default (:issue:`3891`, :issue:`2582`). Previously, operations would drop attributes unless explicitly told to preserve them via ``keep_attrs=True``. Additionally, when attributes are preserved in binary operations, they now combine attributes from both operands using ``drop_conflicts`` (keeping matching attributes, dropping conflicts), instead of keeping @@ -129,7 +36,7 @@ Breaking changes .. code-block:: python - # Before (xarray <2025.09.1): + # Before (xarray <2025.11.0): data = xr.DataArray([1, 2, 3], attrs={"units": "meters", "long_name": "height"}) result = data.mean() result.attrs # {} - Attributes lost! @@ -205,6 +112,98 @@ Breaking changes By `Maximilian Roos `_. + +Bug Fixes +~~~~~~~~~ +- Fix h5netcdf backend for format=None, use same rule as netcdf4 backend (:pull:`10859`). + By `Kai Mühlbauer `_. +- ``netcdf4`` and ``pydap`` backends now use stricter URL detection to avoid incorrectly claiming + remote URLs. The ``pydap`` backend now only claims URLs with explicit DAP protocol indicators + (``dap2://`` or ``dap4://`` schemes, or ``/dap2/`` or ``/dap4/`` in the URL path). This prevents + both backends from claiming remote Zarr stores and other non-DAP URLs without an explicit + ``engine=`` argument (:pull:`10804`). + By `Ian Hunt-Isaak `_. +- Fix indexing with empty arrays for scipy & h5netcdf backends which now resolves to empty slices (:issue:`10867`, :pull:`10870`). + By `Kai Mühlbauer `_ +- Fix error handling issue in ``decode_cf_variables`` when decoding fails - the exception is now re-raised + correctly, with a note added about the variable name that caused the error (:issue:`10873`, :pull:`10886`). + By `Jonas L. Bertelsen `_. +- Fix ``equivalent`` for numpy scalar nan comparison (:issue:`10833`, :pull:`10838`). + By `Maximilian Roos `_. +- Support non-``DataArray`` outputs in :py:meth:`Dataset.map` (:issue:`10835`, :pull:`10839`). + By `Maximilian Roos `_. +- Support ``drop_sel`` on ``MultiIndex`` objects (:issue:`10862`, :pull:`10863`). + By `Aled Owen `_. + +Performance +~~~~~~~~~~~ + +- Speedup and reduce memory usage of :py:func:`concat`. Magnitude of improvement scales + with size of the concatenation dimension (:issue:`10864`, :pull:`10866`). + By `Deepak Cherian `_. + +Documentation +~~~~~~~~~~~~~ + +.. _whats-new.2025.10.1: + +v2025.10.1 (October 7, 2025) +---------------------------- + +This release reverts a breaking change to Xarray's preferred netCDF backend. + +Breaking changes +~~~~~~~~~~~~~~~~ + +- Xarray's default engine for reading/writing netCDF files has been reverted to + prefer netCDF4 over h5netcdf over scipy, which was the default before + v2025.09.1. This change had larger implications for the ecosystem than we + anticipated. We are still considering changing the default in the future, but + will be a bit more careful about the implications. See :issue:`10657` and + linked issues for discussion. The behavior can still be customized, e.g., with + ``xr.set_options(netcdf_engine_order=['h5netcdf', 'netcdf4', 'scipy'])``. + By `Stephan Hoyer `_. + +New features +~~~~~~~~~~~~ + +- Coordinates are ordered to match dims when displaying Xarray objects. (:pull:`10778`). + By `Julia Signell `_. + +Bug fixes +~~~~~~~~~ +- Fix error raised when writing scalar variables to Zarr with ``region={}`` + (:pull:`10796`). + By `Stephan Hoyer `_. + + +.. _whats-new.2025.09.1: + +v2025.09.1 (September 29, 2025) +------------------------------- + +This release contains improvements to netCDF IO and the +:py:func:`DataTree.from_dict` constructor, as well as a variety of bug fixes. +In particular, the default netCDF backend has switched from netCDF4 to h5netcdf, +which is typically faster. + +Thanks to the 17 contributors to this release: +Claude, Deepak Cherian, Dimitri Papadopoulos Orfanos, Dylan H. Morris, Emmanuel Mathot, Ian Hunt-Isaak, Joren Hammudoglu, Julia Signell, Justus Magin, Maximilian Roos, Nick Hodgskin, Spencer Clark, Stephan Hoyer, Tom Nicholas, gronniger, joseph nowak and pierre-manchon + +New Features +~~~~~~~~~~~~ + +- :py:func:`DataTree.from_dict` now supports passing in ``DataArray`` and nested + dictionary values, and has a ``coords`` argument for specifying coordinates as + ``DataArray`` objects (:pull:`10658`). +- ``engine='netcdf4'`` now supports reading and writing in-memory netCDF files. + All of Xarray's netCDF backends now support in-memory reads and writes + (:pull:`10624`). + By `Stephan Hoyer `_. + +Breaking changes +~~~~~~~~~~~~~~~~ + - :py:meth:`Dataset.update` now returns ``None``, instead of the updated dataset. This completes the deprecation cycle started in version 0.17. The method still updates the dataset in-place. (:issue:`10167`)