ensures that the fill_value of a v3 array is an instance of that array's dtype. The behavior here matches numpy type casting rules, so if dtype is bool and the fill_value is provided as 1, the resulting fill_value metadata will be True. I'm happy to change this behavior, but for now this is expedient and matches what people might expect from v2 and numpy
refactors the metadata classes by partitioning v2 and v3 metadata into src/zarr/metadata/v2.py and src/zarr/metadata/v2.py, respectively
TODO:
[ ] Add unit tests and/or doctests in docstrings
[ ] Add docstrings and API docs for any new/modified user-facing classes and functions
[ ] New/modified features documented in docs/tutorial.rst
fill_value
of a v3 array is an instance of that array's dtype. The behavior here matches numpy type casting rules, so ifdtype
isbool
and thefill_value
is provided as1
, the resultingfill_value
metadata will beTrue
. I'm happy to change this behavior, but for now this is expedient and matches what people might expect from v2 and numpysrc/zarr/metadata/v2.py
andsrc/zarr/metadata/v2.py
, respectivelyTODO: