Skip to content

Commit 1e55903

Browse files
committed
Apply ruff format to keep CI linter happy
1 parent 9f5bf46 commit 1e55903

File tree

5 files changed

+6
-2
lines changed

5 files changed

+6
-2
lines changed

src/blosc2/c2array.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
import numpy as np
1919

2020
import blosc2
21+
2122
if not blosc2.IS_WASM:
2223
import httpx
2324

src/blosc2/ndarray.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2776,12 +2776,14 @@ def _check_shape(shape):
27762776
raise TypeError("shape should be a tuple or a list!")
27772777
return shape
27782778

2779+
27792780
def _check_dtype(dtype):
27802781
dtype = np.dtype(dtype)
27812782
if dtype.itemsize > blosc2.MAX_TYPESIZE:
27822783
raise ValueError(f"dtype itemsize {dtype.itemsize} is too large (>{blosc2.MAX_TYPESIZE})!")
27832784
return dtype
27842785

2786+
27852787
def empty(shape: int | tuple | list, dtype: np.dtype | str | None = np.float64, **kwargs: Any) -> NDArray:
27862788
"""Create an empty array.
27872789

tests/conftest.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
def pytest_configure(config):
1616
blosc2.print_versions()
1717

18+
1819
@pytest.fixture(scope="session")
1920
def c2sub_context():
2021
# You may use the URL and credentials for an already existing user

tests/ndarray/test_nans.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def test_nans_simple(shape, dtype):
3131

3232
@pytest.mark.parametrize("asarray", [True, False])
3333
@pytest.mark.parametrize("typesize", [1, 3, 255, 256, 257, 256 * 256])
34-
@pytest.mark.parametrize("shape", [(1,), (3,), (10,), (2*10,)])
34+
@pytest.mark.parametrize("shape", [(1,), (3,), (10,), (2 * 10,)])
3535
def test_large_typesize(shape, typesize, asarray):
3636
dtype = np.dtype([("f_001", "f8", (typesize,)), ("f_002", "f4", (typesize,))])
3737
a = np.full(shape, np.nan, dtype=dtype)

tests/ndarray/test_zeros.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ def test_zeros_minimal(shape, dtype):
126126

127127
@pytest.mark.parametrize("asarray", [True, False])
128128
@pytest.mark.parametrize("typesize", [255, 256, 257, 261, 256 * 256])
129-
@pytest.mark.parametrize("shape", [(1,), (3,), (10,), (2*10,), (2**8 - 1, 3)])
129+
@pytest.mark.parametrize("shape", [(1,), (3,), (10,), (2 * 10,), (2**8 - 1, 3)])
130130
def test_large_typesize(shape, typesize, asarray):
131131
dtype = np.dtype([("f_001", "<i1", (typesize,)), ("f_002", "f4", (typesize,))])
132132
a = np.zeros(shape, dtype=dtype)

0 commit comments

Comments
 (0)