Skip to content

fix: also require kerchunk for test_read_netcdf3#998

Merged
TomNicholas merged 1 commit into
zarr-developers:mainfrom
TomNicholas:fix-netcdf3-test-requires-kerchunk
May 18, 2026
Merged

fix: also require kerchunk for test_read_netcdf3#998
TomNicholas merged 1 commit into
zarr-developers:mainfrom
TomNicholas:fix-netcdf3-test-requires-kerchunk

Conversation

@TomNicholas

Copy link
Copy Markdown
Member

Summary

  • test_read_netcdf3 only had @requires_scipy, but NetCDF3Parser.__call__ lazily imports kerchunk.netCDF3. In any environment that has scipy without kerchunk, the test raised ModuleNotFoundError instead of being skipped. Surfaced by the min-deps-build job on Dmrpp migration #902 once a transitive dep started pulling in scipy there. Adds @requires_kerchunk.

Test plan

  • CI min-deps-build passes (scipy installed, kerchunk not — test should now skip).
  • CI full test envs still run the test (both scipy and kerchunk present).

NetCDF3Parser lazily imports kerchunk.netCDF3 inside __call__, but the
test only had @requires_scipy. In environments that ship scipy without
kerchunk (e.g. pixi min-deps once a transitive dep pulled in scipy) the
test raised ModuleNotFoundError instead of being skipped.
@codecov

codecov Bot commented May 18, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.04%. Comparing base (abd7d0f) to head (35d4c38).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #998      +/-   ##
==========================================
+ Coverage   89.98%   90.04%   +0.06%     
==========================================
  Files          33       33              
  Lines        2066     2089      +23     
==========================================
+ Hits         1859     1881      +22     
- Misses        207      208       +1     

see 2 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@TomNicholas TomNicholas mentioned this pull request May 18, 2026
7 tasks
@TomNicholas TomNicholas merged commit 74b4fa1 into zarr-developers:main May 18, 2026
17 checks passed
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.

1 participant