-
Notifications
You must be signed in to change notification settings - Fork 7
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
Fix redundant _FillValue
attribute for MPAS fields
#259
Conversation
Previously, the `write_netcdf()` function was trying to add a `_FillValue` attribute to variables even if they already had one. With this change, we skip variables that already have a fill value defined
@chengzhuzhang and @TonyB9000, I'm not really in a good position to test this. Can one of you give it a try on the data that was failing for @TonyB9000 before? I'm happy to iterate if needed. |
I'm not sure if this addresses #255 completely or if there are multiple bugs there. I left it out of the description above for now. |
It looks like CI is broken and it's nothing to do with my PR? |
@xylar I approve. The change looks perfectly harmless to me. I will run tests to see if this served to address the fault. |
@TonyB9000 have you confirmed that Xylar's fix has resolved this issue? |
@chengzhuzhang Yes - all of the v2_1 Omon (20+) that were failing were able to complete successfully, I should have followed up here - got distracted with other issues. Of course, why this would be an issue (adding a _fillValue to variables that already have one) is a mystery, but checking first and avoiding the "add" solved the problem. |
@TonyB9000 thank you for confirming. And thank you @xylar for the fix! |
@chengzhuzhang @xylar This issue (#259) and issue (#255) appear related and fixed. However, #255 also overlapped with the "lock=True/lock=False" issue, which (I believe) was resolved by completely eliding the inclusion of "lock=" in the command where it had appeared. Should we close these issues? |
Previously, the
write_netcdf()
function was trying to add a_FillValue
attribute to variables even if they already had one. With this change, we skip variables that already have a fill value definedDescription
Checklist
If applicable: