Auto-generate zero data for missing data payload #362
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull-request extends the capability of the
iris_grib.message._DataProxyto detect and auto-generate missing data payload for a GRIB2 message.The scenario is that the message data payload is all zero, and rather than serialize this within the message, thus increasing the footprint, an application can generate the data at runtime whenever the Data Representation Section [5] has
bitsPerValue=0and an empty Data Section [7].Failure to support this extension results in no encoded Data Section [7] within a
iris_grib.message._RawGribMessagecausing aKeyErrortraceback within the user script. The impact of this is that an N-D Iris cube can be loaded but whenever at least one GRIB2 message has such missing data, touching the cube data will result in this failure.Reference: SciTools/iris-test-data#89