Skip to content

Redirect ALL un-loadable NetCDF objects to LOAD_PROBLEMS #6465

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

trexfeathers
Copy link
Contributor

@trexfeathers trexfeathers commented May 13, 2025

🚀 Pull Request

Description

Closes #6319

Objects

  • Auxiliary coordinates
  • Introduce LoadProblems.Problem.handled flag
  • Introduce LoadProblems.Problem.destination attribute, for maximum context
  • Refactor existing changes to capture objects being added to non-Cube objects too
  • Cube units
  • Cell methods
  • Cube attributes
  • Coordinate systems
  • Cell measures
  • Ancillary variables
  • Mesh content

Consult Iris pull request check list


Add any of the below labels to trigger actions on this PR:

  • benchmark_this Request that this pull request be benchmarked to check if it introduces performance shifts

Copy link

codecov bot commented May 13, 2025

Codecov Report

Attention: Patch coverage is 98.21429% with 2 lines in your changes missing coverage. Please review.

Project coverage is 89.83%. Comparing base (16c6a33) to head (5685f82).
Report is 9 commits behind head on main.

Files with missing lines Patch % Lines
lib/iris/fileformats/_nc_load_rules/helpers.py 97.33% 0 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6465      +/-   ##
==========================================
+ Coverage   89.80%   89.83%   +0.02%     
==========================================
  Files          90       90              
  Lines       23755    23829      +74     
  Branches     4418     4429      +11     
==========================================
+ Hits        21334    21407      +73     
  Misses       1672     1672              
- Partials      749      750       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

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

Comment on lines +490 to +491
# TODO: is it acceptable to use dataclass instead of NamedTuple purely
# because the docs render cleaner?!
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@@ -48,7 +48,7 @@
<dimCoord id="62e940e0" points="[10, 20, 30]" shape="(3,)" standard_name="longitude" units="Unit('degrees')" value_type="int32" var_name="lon"/>
</coord>
<coord datadims="[0]">
<auxCoord id="cb784457" points="[ 1, 100, 3]" shape="(3,)" standard_name="time" units="Unit('hours since 1970-01-01 00:00:00', calendar='standard')" value_type="int32" var_name="time3"/>
<auxCoord id="cb784457" points="[ 1, --, 3]" shape="(3,)" standard_name="time" units="Unit('hours since 1970-01-01 00:00:00', calendar='standard')" value_type="int32" var_name="time3"/>
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This may look like I'm just changing the test to suit me! But I believe my changes have actually improved how Iris works. Our previous graceful fallback on to AuxCoord involved using the DimCoord arguments for AuxCoord creation - so no masking - whereas we are now fully retrying the whole process if DimCoord fails.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: No status
Development

Successfully merging this pull request may close these issues.

Capture ALL un-loadable NetCDF objects
1 participant