Skip to content

Conversation

@lewisjared
Copy link
Contributor

Summary

  • Fix validate_cmec_bundles to check that bundle dimensions are a subset of diagnostic facets, rather than requiring exact equality
  • Different data requirements (CMIP6 vs obs4MIPs) have different group_by fields that get prepended as dimensions via prepend_dimensions, so bundle dimensions legitimately vary per execution

Fixes the regional-historical-trend/obs4mips test case where the bundle produces (source_id, variable_id, region, metric) but facets also includes grid_label and member_id from the CMIP6 group_by.

Test plan

  • TestValidateCmecBundles unit tests pass (3/3)
  • All pre-commit hooks pass

Different data requirements (e.g. CMIP6 vs obs4MIPs) have different
group_by fields, so bundle dimensions vary per execution. The validation
now checks that bundle dimensions are a subset of diagnostic facets
rather than requiring an exact match.

Fixes obs4MIPs test case for regional-historical-trend where the bundle
has (source_id, variable_id, region, metric) but facets also include
grid_label and member_id from the CMIP6 group_by.
@codecov
Copy link

codecov bot commented Feb 10, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

Files with missing lines Coverage Δ
...s/climate-ref-core/src/climate_ref_core/testing.py 93.08% <100.00%> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@lewisjared lewisjared merged commit 811780f into main Feb 10, 2026
25 checks passed
@lewisjared lewisjared deleted the fix/validate-cmec-bundle-subset-check-v2 branch February 10, 2026 03:57
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