Skip to content

Commit a1d9ac5

Browse files
committed
Attempting isort fix, version 6.0 doesn't agree with black about format choices
Signed-off-by: Eric Kerfoot <[email protected]>
1 parent 4b5759c commit a1d9ac5

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

requirements-dev.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ pep8-naming
1818
pycodestyle
1919
pyflakes
2020
black>=22.12
21-
isort>=5.1
21+
isort>=5.1, <6.0
2222
ruff
2323
pytype>=2020.6.1; platform_system != "Windows"
2424
types-setuptools

tests/test_meta_tensor.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,7 @@ def test_pickling(self):
256256
with tempfile.TemporaryDirectory() as tmp_dir:
257257
fname = os.path.join(tmp_dir, "im.pt")
258258
torch.save(m, fname)
259-
m2 = torch.load(fname, weights_only=False)
259+
m2 = torch.load(fname)
260260
if not isinstance(m2, MetaTensor) and not pytorch_after(1, 8, 1):
261261
warnings.warn("Old version of pytorch. pickling converts `MetaTensor` to `torch.Tensor`.")
262262
m = m.as_tensor()

tests/test_zarr_avg_merger.py

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

203203
# test for LZ4 compressor
204204
TEST_CASE_13_COMPRESSOR_LZ4 = [
205-
dict(merged_shape=TENSOR_4x4.shape, compressor=zarr.codecs.BloscCodec),
205+
dict(merged_shape=TENSOR_4x4.shape, compressor="LZ4"),
206206
[
207207
(TENSOR_4x4[..., :2, :2], (0, 0)),
208208
(TENSOR_4x4[..., :2, 2:], (0, 2)),
@@ -291,7 +291,7 @@ def test_zarr_avg_merger_patches(self, arguments, patch_locations, expected):
291291
codec_reg = numcodecs.registry.codec_registry
292292
if "compressor" in arguments:
293293
if arguments["compressor"] != "default":
294-
arguments["compressor"] = arguments["compressor"]
294+
arguments["compressor"] = codec_reg[arguments["compressor"].lower()]()
295295
if "value_compressor" in arguments:
296296
if arguments["value_compressor"] != "default":
297297
arguments["value_compressor"] = codec_reg[arguments["value_compressor"].lower()]()

0 commit comments

Comments
 (0)