Skip to content

Commit 5e6daba

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 9db951c commit 5e6daba

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

Diff for: xarray/backends/zarr.py

+5-2
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ def encode_zarr_attr_value(value):
180180

181181

182182
class ZarrArrayWrapper(BackendArray):
183-
__slots__ = ("_array", "dtype", "shape", "is_coordinate")
183+
__slots__ = ("_array", "dtype", "is_coordinate", "shape")
184184

185185
def __init__(self, zarr_array, is_coordinate: bool):
186186
# some callers attempt to evaluate an array if an `array` property exists on the object.
@@ -212,6 +212,7 @@ def _vindex(self, key):
212212

213213
def _getitem(self, key):
214214
from zarr.core.buffer.cpu import buffer_prototype
215+
215216
if self.is_coordinate:
216217
prototype = buffer_prototype
217218
else:
@@ -816,7 +817,9 @@ def ds(self):
816817
def open_store_variable(self, name):
817818
zarr_array = self.members[name]
818819
is_coordinate = name in zarr_array.metadata.dimension_names
819-
data = indexing.LazilyIndexedArray(ZarrArrayWrapper(zarr_array, is_coordinate=is_coordinate))
820+
data = indexing.LazilyIndexedArray(
821+
ZarrArrayWrapper(zarr_array, is_coordinate=is_coordinate)
822+
)
820823
try_nczarr = self._mode == "r"
821824
dimensions, attributes = _get_zarr_dims_and_attrs(
822825
zarr_array, DIMENSION_KEY, try_nczarr

0 commit comments

Comments
 (0)