Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Invalid "selection" values in "read_zarr()" should raise an error

Open Beginner friendly
#1,172 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
78/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
python
Domain
api, data

Research direction

Start at the spatialdata.read_zarr() entry point and inspect how the selection argument is handled. Validate entries against images, labels, points, shapes, and tables, and confirm that an unknown value such as "table" raises a clear ValueError instead of silently omitting data.

Written by the indexing model from the issue text.

Description

needs: triage priority: low

spatialdata.read_zarr() currently appears to silently ignore invalid values passed to selection.

For example:

sdata = spatialdata.read_zarr(
    path,
    selection=("table",),
)

returns a SpatialData object with no loaded tables instead of indicating that "table" is not a valid selector.

It would be safer if read_zarr() validated selection against the supported values:

{"images", "labels", "points", "shapes", "tables"}

and raised a clear ValueError for unknown entries. Silent failure can otherwise make a valid Zarr store look empty and is difficult to diagnose.

Dominant language
Python
Stars
394
Forks
95
Avg merge
3d 9h
Merged PRs (30d)
5

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from scverse/spatialdata

All issues in scverse/spatialdata

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.