• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

thanos / ExZarr / 608a06b3cb08046d976cdd7d004548104599f7e0-PR-131
65%
main: 76%

Build:
Build:
LAST BUILD BRANCH: nx_integration
DEFAULT BRANCH: main
Ran 25 Jan 2026 08:14PM UTC
Jobs 1
Files 34
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

25 Jan 2026 08:09PM UTC coverage: 65.199% (+1.3%) from 63.945%
608a06b3cb08046d976cdd7d004548104599f7e0-PR-131

Pull #131

github

thanos
closed #129
New Functions Added to lib/ex_zarr/metadata_v3.ex

  1. to_json/1 - Converts MetadataV3 struct to JSON string
    - Leverages existing Jason.Encoder implementation
    - Returns {:ok, json_string} or {:error, reason}
    - Properly handles all v3 features
  2. from_json/1 - Parses JSON (string or map) to MetadataV3 struct
    - Handles both JSON strings and decoded maps
    - Converts lists to tuples for shape/chunk_shape
    - Parses string node_type ("array", "group") to atoms
    - Returns {:ok, metadata} or {:error, reason}
  3. Helper parsing functions (238 lines total):
    - parse_metadata_map/1 - Main parsing logic
    - parse_node_type/1 - Converts string to atom
    - parse_shape/1 - Converts lists to tuples
    - parse_chunk_grid/1 - Handles regular and irregular grids
    - parse_chunk_grid_config/2 - Grid-specific parsing
    - parse_codecs/1 - Parses codec pipeline
    - parse_codec/1 - Individual codec parsing
    - parse_codec_configuration/2 - Codec-specific config (especially sharding)

  Comprehensive Test Suite Added to test/ex_zarr/metadata_v3_test.exs

  Added 54 new tests (547 lines) covering:

  1. JSON Encoding (to_json/1) - 5 tests
    - Basic array metadata
    - Group metadata
    - Dimension names
    - Sharding codec with nested configurations
    - Storage transformers (transpose, quantize, bitround)
  2. JSON Decoding (from_json/1) - 10 tests
    - Parsing from JSON string
    - Parsing from map
    - Group metadata
    - Dimension names
    - Sharding codec with nested configurations
    - Storage transformers
    - Round-trip encoding/decoding
    - Error handling (invalid JSON, missing fields, invalid input types)
  3. Zarr-Python File Compatibility - 5 tests
    - Write/read zarr.json file
    - Sharded array metadata
    - Group metadata
    - Irregular chunk grid parsing
    - Full round-trip file I/O

   Features Fully Supported

  The implementation handles all Zarr v3 features:

  -  Regular chunk g... (continued)
Pull Request #131: closed #129

40 of 63 new or added lines in 1 file covered. (63.49%)

1806 of 2770 relevant lines covered (65.2%)

1118.24 hits per line

New Missed Lines in Diff

Lines Coverage ∆ File
23
78.13
19.99% lib/ex_zarr/metadata_v3.ex
Jobs
ID Job ID Ran Files Coverage
1 608a06b3cb08046d976cdd7d004548104599f7e0-PR-131.1 25 Jan 2026 08:14PM UTC 34
65.2
GitHub Action Run
Source Files on build 608a06b3cb08046d976cdd7d004548104599f7e0-PR-131
  • Tree
  • List 34
  • Changed 1
  • Source Changed 0
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Pull Request #131
  • PR Base - main (#95336C33...)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc