Skip to content

ValueError on empty slice after resize() with fsspec store #1341

Description

@sbalmer

When using fsspec as store, the Array throws a ValueError when selecting an empty slice(), but only after resizing:

import fsspec
import zarr

fs = fsspec.filesystem('memory')
store = zarr.storage.FSStore('/test', fs=fs)
arr = zarr.create((0,), store=store)

# These print "[]" as expected
print(arr[0:0])
print(arr[1:1])

arr.resize((1,))

# These raise ValueError
print(arr[0:0])
print(arr[1:1])

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugPotential issues with the zarr-python library

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions