Skip to content

Commit 4ed41c6

Browse files
committed
mid-refactor commit
1 parent b588f70 commit 4ed41c6

File tree

5 files changed

+80
-301
lines changed

5 files changed

+80
-301
lines changed

src/zarr/core/_info.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
from zarr.abc.codec import ArrayArrayCodec, ArrayBytesCodec, BytesBytesCodec
99
from zarr.core.common import ZarrFormat
10-
from zarr.core.metadata.dtype import DTypeBase
10+
from zarr.core.metadata.dtype import DTypeWrapper
1111

1212
# from zarr.core.metadata.v3 import DataType
1313

@@ -80,7 +80,7 @@ class ArrayInfo:
8080

8181
_type: Literal["Array"] = "Array"
8282
_zarr_format: ZarrFormat
83-
_data_type: np.dtype[Any] | DTypeBase
83+
_data_type: np.dtype[Any] | DTypeWrapper
8484
_shape: tuple[int, ...]
8585
_shard_shape: tuple[int, ...] | None = None
8686
_chunk_shape: tuple[int, ...] | None = None

src/zarr/core/array.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@
9898
ArrayV3MetadataDict,
9999
T_ArrayMetadata,
100100
)
101-
from zarr.core.metadata.dtype import DTypeBase
101+
from zarr.core.metadata.dtype import DTypeWrapper
102102
from zarr.core.metadata.v2 import (
103103
_default_compressor,
104104
_default_filters,
@@ -699,7 +699,7 @@ def _create_metadata_v3(
699699

700700
if fill_value is None:
701701
# v3 spec will not allow a null fill value
702-
fill_value_parsed = dtype.type(zarr_data_type.default)
702+
fill_value_parsed = dtype.type(zarr_data_type._default_value)
703703
else:
704704
fill_value_parsed = fill_value
705705

@@ -1694,7 +1694,7 @@ async def info_complete(self) -> Any:
16941694
def _info(
16951695
self, count_chunks_initialized: int | None = None, count_bytes_stored: int | None = None
16961696
) -> Any:
1697-
_data_type: np.dtype[Any] | DTypeBase
1697+
_data_type: np.dtype[Any] | DTypeWrapper
16981698
if isinstance(self.metadata, ArrayV2Metadata):
16991699
_data_type = self.metadata.dtype
17001700
else:

0 commit comments

Comments
 (0)