Skip to content
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

Enable use of _FillValue for identifying missing values in input files #21

Merged
merged 4 commits into from
Dec 14, 2022

Conversation

lizziel
Copy link

@lizziel lizziel commented May 16, 2022

This PR is 1 of 2 for GCHP super-project. See instructions here:
geoschem/GCHP#258

Description

For single precision attribute retrieval there is now handling for double precision input. This update also expands error handling in FileMetadataUtilities to print filename in all calls to _ASSERT and _FAIL. Fail messages about unsupported attribute type now specify the unique type constraint per function.

Related Issue

Closes geoschem/GCHP#183

Motivation and Context

This update prevents run fail when retrieving _FillValue from import files containing double precision data used GCHP. It also expands the error handling so that failure on reading import attributes always results in a unique message with the filename, making it easier to find and fix the problem.

How Has This Been Tested?

Tested in GCHP branch with upgraded GMAO libraries going into 14.0.0.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Trivial change (affects only documentation or cleanup)

Additional information / dependencies

In order for this update to fix GFAS there needs to be a modified version of one of the GEOS-Chem input files. I will submit that change as a GEOS-Chem repo PR.

These changes have been submitted to GMAO in GEOS-ESM#1506.

@lizziel lizziel self-assigned this May 16, 2022
@lizziel lizziel added the bug Something isn't working label May 16, 2022
@lizziel lizziel requested a review from LiamBindle May 16, 2022 20:41
@lizziel lizziel added enhancement New feature or request and removed bug Something isn't working labels May 16, 2022
@lizziel
Copy link
Author

lizziel commented May 17, 2022

This PR should not be merged until after geoschem/geos-chem#1255.

@stale
Copy link

stale bot commented Jul 25, 2022

This issue has been automatically marked as stale because it has not had recent activity. If there are no updates within 7 days, it will be closed. You can add the "long term" tag to prevent the Stale bot from closing this issue.

@stale stale bot added the stale label Jul 25, 2022
@lizziel lizziel removed the stale label Jul 25, 2022
@lizziel lizziel added the long term Will not get stale label Aug 29, 2022
Signed-off-by: Lizzie Lundgren <elundgren@seas.harvard.edu>
Signed-off-by: Lizzie Lundgren <elundgren@seas.harvard.edu>
This update also include minor changes to how fname set in the metadata
utilities file.

Signed-off-by: Lizzie Lundgren <elundgren@seas.harvard.edu>
@lizziel
Copy link
Author

lizziel commented Oct 17, 2022

The HEMCO PR that goes with this update is now ready for review at geoschem/HEMCO#171. I made @msulprizio reviewer for both since they go together.

Copy link

@msulprizio msulprizio left a comment

Choose a reason for hiding this comment

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

These changes look good to merge. Thank you for adding the more detailed error messages here too!

@lizziel lizziel changed the title Expand allowed _FillValue type and error handling in FileMetadataUtilities.F90 Enable use of _FillValue for identifying missing values in input files Oct 18, 2022
@msulprizio msulprizio merged commit 191585d into gchp/dev Dec 14, 2022
@msulprizio msulprizio deleted the feature/FillValue_handling_fix branch December 14, 2022 19:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request long term Will not get stale
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG/ISSUE] Error in GCHP with GFAS
2 participants