Skip to content
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

Bump minimum Xarray dependency to 2024.10.0 #284

Merged
merged 5 commits into from
Nov 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ci/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ dependencies:
- h5py
- hdf5
- netcdf4
- xarray>=2024.6.0
- xarray>=2024.10.0
- kerchunk>=0.2.5
- numpy>=2.0.0
- ujson
Expand Down
2 changes: 1 addition & 1 deletion ci/min-deps.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ dependencies:
- h5py
- hdf5
- netcdf4
- xarray>=2024.6.0
- xarray>=2024.10.0
- numpy>=2.0.0
- numcodecs
- packaging
Expand Down
2 changes: 1 addition & 1 deletion ci/upstream.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ channels:
- conda-forge
- nodefaults
dependencies:
- xarray>=2024.10.0
- h5netcdf
- h5py
- hdf5
Expand All @@ -25,6 +26,5 @@ dependencies:
- pip
- pip:
- icechunk # Installs zarr v3 as dependency
- git+https://github.com/pydata/xarray@zarr-v3 # zarr-v3 compatibility branch
- git+https://github.com/zarr-developers/numcodecs@zarr3-codecs # zarr-v3 compatibility branch
# - git+https://github.com/fsspec/kerchunk@main # kerchunk is currently incompatible with zarr-python v3 (https://github.com/fsspec/kerchunk/pull/516)
2 changes: 2 additions & 0 deletions docs/releases.rst
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ Breaking changes
- VirtualiZarr's `ZArray`, `ChunkEntry`, and `Codec` no longer subclass
`pydantic.BaseModel` (:pull:`210`)
- `ZArray`'s `__init__` signature has changed to match `zarr.Array`'s (:pull:`210`)
- Minimum required version of Xarray is now v2024.10.0.
(:pull:`284`) By `Tom Nicholas <https://github.com/TomNicholas>`_.

Deprecations
~~~~~~~~~~~~
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ classifiers = [
requires-python = ">=3.10"
dynamic = ["version"]
dependencies = [
"xarray>=2024.06.0",
"xarray>=2024.10.0",
"numpy>=2.0.0",
"packaging",
"universal-pathlib",
Expand Down
10 changes: 2 additions & 8 deletions virtualizarr/readers/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
from collections.abc import Iterable, Mapping, MutableMapping
from io import BufferedIOBase
from typing import (
TYPE_CHECKING,
Any,
Hashable,
Optional,
Expand All @@ -14,6 +13,7 @@
from xarray import (
Coordinates,
Dataset,
DataTree,
Index,
IndexVariable,
Variable,
Expand All @@ -26,12 +26,6 @@

XArrayOpenT = str | os.PathLike[Any] | BufferedIOBase | AbstractDataStore

if TYPE_CHECKING:
try:
from xarray import DataTree # type: ignore[attr-defined]
except ImportError:
DataTree = Any


def open_loadable_vars_and_indexes(
filepath: str,
Expand Down Expand Up @@ -194,5 +188,5 @@ def open_virtual_datatree(
decode_times: bool | None = None,
indexes: Mapping[str, Index] | None = None,
reader_options: Optional[dict] = None,
) -> "DataTree":
) -> DataTree:
raise NotImplementedError()
Loading