Skip to content

SpatialData 0.8.0 permits Zarr versions that do not provide ArrayNotFoundError #1256

Description

@Darlokt

Report

Hej everyone,
I found and error while working.
SpatialData 0.8.0 declares zarr>=3.0.0, but its persistence module imports ArrayNotFoundError from zarr.errors.
That exception is unavailable in Zarr 3.0.0 through 3.1.1 and was added in Zarr 3.1.2.
Consequently, dependency resolution can produce a valid environment according to the published package metadata in which importing read_zarr fails.

Minimal reproduction

In a clean environment:

$ uv run --isolated --python 3.12 \
    --with 'spatialdata==0.8.0' \
    --with 'zarr==3.1.1' \
    python -c 'from spatialdata import read_zarr'
ImportError: cannot import name 'ArrayNotFoundError' from 'zarr.errors'

The same failure occurs with Zarr 3.0.0 and 3.1.0. The import succeeds with
Zarr 3.1.2:

$ uv run --isolated --python 3.12 \
    --with 'spatialdata==0.8.0' \
    --with 'zarr==3.1.2' \
    python -c 'from spatialdata import read_zarr; print(read_zarr.__name__)'
read_zarr

Versions

| Package     | Version |
| ----------- | ------- |
| spatialdata | 0.8.0   |
| zarr        | 3.1.1   |

| Dependency               | Version                |
| ------------------------ | ---------------------- |
| google-crc32c            | 1.8.0                  |
| wrapt                     | 2.1.2                  |
| dask                      | 2026.8.0               |
| numcodecs                 | 0.16.5                 |
| typing_extensions         | 4.15.0                 |
| natsort                   | 8.4.0                  |
| scipy                     | 1.17.1                 |
| packaging                 | 26.2                   |
| six                       | 1.17.0                 |
| array-api-compat          | 1.14.0                 |
| typing-inspection         | 0.4.2                  |
| crc32c                    | 2.9.post0              |
| pandas                    | 2.3.3                  |
| charset-normalizer       | 3.4.7                  |
| transformnd              | 0.7.2                  |
| zstandard                | 0.25.0                 |
| legacy-api-wrap          | 1.5                    |
| Deprecated               | 1.3.1                  |
| pydantic                 | 2.12.5                 |
| pytz                     | 2026.2                 |
| scikit-image             | 0.26.0                 |
| shapely                  | 2.1.2                  |
| setuptools               | 82.0.1                 |
| tblib                    | 3.2.2                  |
| pydantic_core            | 2.41.5                 |
| certifi                  | 2026.4.22 (2026.04.22) |
| Jinja2                   | 3.1.6                  |
| lazy-loader              | 0.5                    |
| scverse-misc             | 0.1.6                  |
| pyarrow                  | 24.0.0                 |
| pyproj                   | 3.7.2                  |
| cloudpickle              | 3.1.2                  |
| fsspec                   | 2026.4.0               |
| numpy                    | 2.4.5                  |
| PyYAML                   | 6.0.3                  |
| xarray                   | 2026.4.0               |
| ome-zarr-models          | 1.8.1                  |
| session-info2            | 0.4.1                  |
| toolz                    | 1.1.0                  |
| spatial_image            | 1.2.3                  |
| rich                     | 15.0.0                 |
| xarray-dataclass         | 3.0.0                  |
| python-dateutil          | 2.9.0.post0            |
| MarkupSafe               | 3.0.3                  |
| annotated-types          | 0.7.0                  |
| psutil                   | 7.2.2                  |
| networkx                 | 3.6.1                  |
| h5py                     | 3.16.0                 |
| anndata                  | 0.12.14                |
| pydantic-zarr            | 0.10.0                 |
| geopandas                | 1.1.3                  |
| ome-zarr                 | 0.19.2                 |
| donfig                   | 0.8.1.post1            |
| multiscale_spatial_image | 2.0.3                  |
| msgpack                  | 1.1.2                  |

| Component | Info                                                          |
| --------- | ------------------------------------------------------------- |
| Python    | 3.12.3 (main, Aug 31 2026, 10:18:26) [GCC 13.3.0]             |
| OS        | Linux-6.18.33.2-microsoft-standard-WSL2-x86_64-with-glibc2.39 |
| Updated   | 2026-09-21 20:54                                              |

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions