You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When loading any netCDF file, a warning is produced from iris:
FutureWarning: Ignoring a datum in netCDF load for consistency with existing behaviour. In a future version of Iris, this datum will be applied. To apply the datum when loading, use the iris.FUTURE.datum_support flag.
The warning text implies that there is a datum in the file being loaded and it is being ignored. Can the behaviour to trigger the warning be aligned with the warning text, so the warning only fires if there is a datum in the source file?
This would make the warning much more useful for end users: users would only see the warning for those cases where there is a behaviour change controlled by the iris.FUTURE.datum_support flag (and hence where the user may need to understand or do something). At the moment, the warning is emitted for files where there will be no behaviour change too.
How To Reproduce
Steps to reproduce the behaviour:
Load a netCDF file with iris 3.7 (or iris since 3.3ish?)
Expected behaviour
Only seeing the warning for netCDF files that do have a datum defined.
The text was updated successfully, but these errors were encountered:
I reckon it is basically this code which is relevant to this.
I also don't understand why this chooses to issue a warning whenever a coordinate-system is built, and not just "if there is a datum attribute being ignored".
Unless there a good reason, I'd say this can very simply be changed by changing line 475 if not iris.FUTURE.datum_support: to if datum is not None and not iris.FUTURE.datum_support:
This code was added with #4704
Unfortunately, I'm not sure that either contributor or reviewer will be available to re-discuss this, so we may need to make our own decision!
This code was added with #4704
Unfortunately, I'm not sure that either contributor or reviewer will be available to re-discuss this, so we may need to make our own decision!
They can be responsive when asked! @wjbenfold@jamesp anything to add? No worries if you're busy 馃槉
Either I had some arcane reason to do this that's unfathomable to you guys, me and everyone else or I wrote a bug. I'm inclined to believe it's the latter, happy to throw up a PR to fix it as penance if you like but I dare say you'll beat me to it
馃悰 Bug Report
When loading any netCDF file, a warning is produced from iris:
The warning text implies that there is a datum in the file being loaded and it is being ignored. Can the behaviour to trigger the warning be aligned with the warning text, so the warning only fires if there is a datum in the source file?
This would make the warning much more useful for end users: users would only see the warning for those cases where there is a behaviour change controlled by the iris.FUTURE.datum_support flag (and hence where the user may need to understand or do something). At the moment, the warning is emitted for files where there will be no behaviour change too.
How To Reproduce
Steps to reproduce the behaviour:
Expected behaviour
Only seeing the warning for netCDF files that do have a datum defined.
The text was updated successfully, but these errors were encountered: