Skip to content

Commit 00e241e

Browse files
committed
format
1 parent f63bb67 commit 00e241e

File tree

2 files changed

+15
-8
lines changed

2 files changed

+15
-8
lines changed

src/zarr/core/metadata/v3.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,8 @@
3737
)
3838
from zarr.core.config import config
3939
from zarr.core.metadata.common import parse_attributes
40-
from zarr.core.strings import _STRING_DTYPE as STRING_NP_DTYPE, _NUMPY_SUPPORTS_VLEN_STRING
40+
from zarr.core.strings import _NUMPY_SUPPORTS_VLEN_STRING
41+
from zarr.core.strings import _STRING_DTYPE as STRING_NP_DTYPE
4142
from zarr.errors import MetadataValidationError, NodeTypeValidationError
4243
from zarr.registry import get_codec_class
4344

tests/test_config.py

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@
88
import pytest
99

1010
import zarr
11-
from zarr import Array, zeros, AsyncArray
12-
from zarr.abc.codec import CodecInput, CodecOutput, CodecPipeline, Codec
11+
from zarr import Array, AsyncArray, zeros
12+
from zarr.abc.codec import Codec, CodecInput, CodecOutput, CodecPipeline
1313
from zarr.abc.store import ByteSetter, Store
1414
from zarr.codecs import (
1515
BloscCodec,
@@ -25,7 +25,6 @@
2525
from zarr.core.codec_pipeline import BatchedCodecPipeline
2626
from zarr.core.config import BadConfigError, config
2727
from zarr.core.indexing import SelectorTuple
28-
from zarr.core.strings import _STRING_DTYPE
2928
from zarr.registry import (
3029
fully_qualified_name,
3130
get_buffer_class,
@@ -256,13 +255,14 @@ def test_config_buffer_implementation() -> None:
256255
assert np.array_equal(arr_Crc32c[:], data2d)
257256

258257

259-
@pytest.mark.parametrize(("dtype", "expected_codecs"),
258+
@pytest.mark.parametrize(
259+
("dtype", "expected_codecs"),
260260
[
261261
("int", [BytesCodec(), GzipCodec()]),
262262
("bytes", [VLenBytesCodec()]),
263263
("str", [VLenUTF8Codec()]),
264-
]
265-
)
264+
],
265+
)
266266
async def test_default_codecs(dtype: str, expected_codecs: list[Codec]) -> None:
267267
with config.set(
268268
{
@@ -273,5 +273,11 @@ async def test_default_codecs(dtype: str, expected_codecs: list[Codec]) -> None:
273273
}
274274
}
275275
):
276-
arr = await AsyncArray.create(shape=(100,), chunk_shape=(100,),dtype=np.dtype(dtype), zarr_format=3, store=MemoryStore())
276+
arr = await AsyncArray.create(
277+
shape=(100,),
278+
chunk_shape=(100,),
279+
dtype=np.dtype(dtype),
280+
zarr_format=3,
281+
store=MemoryStore(),
282+
)
277283
assert arr.metadata.codecs == expected_codecs

0 commit comments

Comments
 (0)