Skip to content

Commit 10af001

Browse files
committed
Merge branch 'less-warnings' of https://github.com/scverse/spatialdata into less-warnings
2 parents 110a6ce + 81c47a0 commit 10af001

2 files changed

Lines changed: 7 additions & 2 deletions

File tree

tests/io/test_attrs_io.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99

1010
from spatialdata import SpatialData, read_zarr
1111
from spatialdata._io.format import (
12+
CurrentSpatialDataContainerFormat,
1213
SpatialDataContainerFormats,
1314
SpatialDataContainerFormatType,
1415
)

tests/io/test_partial_read.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -473,7 +473,9 @@ def test_read_zarr_with_error(test_case: PartialReadTestCase):
473473
ctx = warnings.catch_warnings() if test_case.zarr_version < 3 else nullcontext()
474474
with ctx:
475475
if test_case.zarr_version < 3:
476-
warnings.filterwarnings("ignore", message="SpatialData is not stored in the most current format", category=UserWarning)
476+
warnings.filterwarnings(
477+
"ignore", message="SpatialData is not stored in the most current format", category=UserWarning
478+
)
477479
if test_case.expected_exceptions:
478480
with pytest.raises(test_case.expected_exceptions):
479481
read_zarr(test_case.path, on_bad_files="error")
@@ -507,7 +509,9 @@ def test_read_zarr_with_warnings(test_case: PartialReadTestCase):
507509
ctx = warnings.catch_warnings() if test_case.zarr_version < 3 else nullcontext()
508510
with ctx:
509511
if test_case.zarr_version < 3:
510-
warnings.filterwarnings("ignore", message="SpatialData is not stored in the most current format", category=UserWarning)
512+
warnings.filterwarnings(
513+
"ignore", message="SpatialData is not stored in the most current format", category=UserWarning
514+
)
511515
with pytest_warns_multiple(UserWarning, matches=test_case.warnings_patterns):
512516
actual: SpatialData = read_zarr(test_case.path, on_bad_files="warn")
513517

0 commit comments

Comments
 (0)