Skip to content

Commit ac5ae5e

Browse files
committed
avoid race condition in append test
1 parent 4ec9bcf commit ac5ae5e

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

zarr/core.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -986,6 +986,8 @@ def _append_nosync(self, data, axis=0):
986986
)
987987
self[append_selection] = data
988988

989+
return new_shape
990+
989991
def view(self, shape=None, chunks=None, dtype=None,
990992
fill_value=None, filters=None, read_only=None,
991993
synchronizer=None):

zarr/tests/test_sync.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,8 @@ def _append(arg):
5454
import numpy as np
5555
x = np.empty(1000, dtype='i4')
5656
x[:] = i
57-
z.append(x)
58-
return z.shape
57+
shape = z.append(x)
58+
return shape
5959

6060

6161
def _set_arange(arg):

0 commit comments

Comments
 (0)