Skip to content

Implement pathway for zipped zarr#775

Open
aulemahal wants to merge 2 commits intointake:mainfrom
Ouranosinc:support-zarr-zip
Open

Implement pathway for zipped zarr#775
aulemahal wants to merge 2 commits intointake:mainfrom
Ouranosinc:support-zarr-zip

Conversation

@aulemahal
Copy link
Contributor

@aulemahal aulemahal commented Jan 22, 2026

Change Summary

When the format is "zarr", the path is a local(able) asset and the path endswith ".zip", this adds a case in source._open_dataset to first ensure a local path, then open a zarr.storage.ZipStore and pass that to xarray.

Storage options are dropped from the xarray args as they were already used by fsspec to make the path local.

I must admit that I'm not completely sure of what ffspec.open_local does and I simply implemented this by copying what was done in the other cases.

Related issue number

Fixes #769.

Checklist

  • Unit tests for the changes exist
  • Tests pass on CI
  • Documentation reflects the changes where applicable

I think this will not interfere with ZEP8's url pipelines once they are implemented because the urlpath of a zipped zarr will not end with ".zip", but rather with a series of |-separated parts.

@aulemahal aulemahal requested a review from mgrover1 as a code owner January 22, 2026 23:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support zipped zarr

1 participant