zarr-developers / zarr-specs

Zarr core protocol for storage and retrieval of N-dimensional typed arrays
https://zarr-specs.readthedocs.io/
Creative Commons Attribution 4.0 International
88 stars 28 forks source link

Can fallback data types have fallbacks? #239

Open clbarnes opened 1 year ago

clbarnes commented 1 year ago

The spec currently allows fallback data types to either be core or extension data types, but disallows the "fallback" field in an extension data type object. If fallbacks are not limited to core types, why not allow further fallbacks?

jbms commented 1 year ago

The spec does say that fallback may be a list of data types: https://github.com/zarr-developers/zarr-specs/blob/cdf97c94d9e6f13dc820a0cd604cc8f9b0d61d03/docs/v3/core/v3.0.rst?plain=1#L494

Note though, that in regard to fallback data types, there is an outstanding issue of how to deal with the fill value: https://github.com/zarr-developers/zarr-specs/pull/236#issuecomment-1539188066

clbarnes commented 1 year ago

Ah, my fault for missing that! I suppose it's just an API decision of a single recursive approach or two very similar APIs.