added gribberish codec support#689
Conversation
There was a problem hiding this comment.
Code Review
This pull request integrates the @mattnucc/gribberish package to decode GRIB2 messages, introducing a custom Zarrita codec (GribberishCodec), configuring WASM loader patching, and updating the dimension mapping logic in useDataFetcher.tsx. Feedback highlights critical improvements: explicitly freeing WebAssembly-backed Rust objects to prevent memory leaks, guarding BigInt conversions against non-finite values to avoid runtime crashes, and adding defensive checks on targetDim to prevent TypeError exceptions on small or empty dimensions.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
This PR adds support to Read GRIB files via icechunk by using the
@mattnucc/gribberishpackage and registering a new code for zarrita.js. Codec conventions were translated from https://github.com/mpiannucci/gribberish/blob/main/python/gribberish/zarr/codec.pyThis will allow users to get access to:
Further reading:
> 14 PBand 1 billion GRIB messages [as one virtual Icechunk store]Caution
For local dev is not enough to simple do
npm installbecause the codec comes as awasmasset.Note that in production we are using
pnpmas the package manager. The newwasmasset gets resolved with thepnpm-workspace.yamlfile. So, before you donpm run dev, is necessary to doand that's it. Now you have the needed
wasminnode_modules. Now doas usual. These instructions should go into a new file,
CONTRIBUTING.md. Will do in another PR.