Skip to content

Commit 74d0995

Browse files
committed
fix bug
1 parent 3766c71 commit 74d0995

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/zarr/core/indexing.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -421,7 +421,9 @@ def __iter__(self) -> Iterator[ChunkDimProjection]:
421421

422422
dim_out_sel = slice(dim_out_offset, dim_out_offset + dim_chunk_nitems)
423423

424-
is_complete_chunk = dim_chunk_sel_start == 0 and (self.stop >= dim_limit)
424+
is_complete_chunk = (
425+
dim_chunk_sel_start == 0 and (self.stop >= dim_limit) and self.step in [1, None]
426+
)
425427
yield ChunkDimProjection(dim_chunk_ix, dim_chunk_sel, dim_out_sel, is_complete_chunk)
426428

427429

0 commit comments

Comments
 (0)