pydata / xarray

N-D labeled arrays and datasets in Python
https://xarray.dev
Apache License 2.0
3.63k stars 1.09k forks source link

Use zarr v3 dimension_names #9669

Closed rabernat closed 1 month ago

rabernat commented 1 month ago
rabernat commented 1 month ago

Question: do we want to handle the case where V3 data have _ARRAY_DIMENSIONS attrs set?

shoyer commented 1 month ago

Question: do we want to handle the case where V3 data have _ARRAY_DIMENSIONS attrs set?

Hopefully such Zarr v3 files do not exist! I am OK skipping this

shoyer commented 1 month ago

Looks good, thanks Ryan!

At some point, it would also probably be a good idea to update our Zarr encoding docs: https://docs.xarray.dev/en/stable/internals/zarr-encoding-spec.html

TomNicholas commented 1 month ago

Are the upstream errors expected / allowed for now? (They are not going to be specific to this issue, but I'm wondering about the release)

TomNicholas commented 1 month ago

Actually this error

AttributeError: 'ArrayV2Metadata' object has no attribute 'dimension_names'

does seem like its relevant to this PR

rabernat commented 1 month ago

Yes thanks for flagging. I'm blaming @shoyer's suggestion in fc3d4c3280f7190719f8e0baf703b783715bcb3b, which broke compatibility with V2 metadata. 😛 Will push a fix later tonight.

TomNicholas commented 1 month ago

This looks good now - the only remaining upstream failures are groupby-related. Merge?