Add support for three-digit gust reports #77
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.
Parsing the following (simplified) report yields a gust value of
4
, which seems to be incorrect.RKPM 091931Z 34028G043KT
I did some research, and while I found it hard to find "official" sources, I believe that I have found ones that are reputable enough. There also seems to be some degree of disagreement between sources, but I think it would be safe to support an extra digit regardless, as it seems that this does in fact occur in real reports.
Here are some extracts from a few sources with varying amounts of explicit specifications:
This PR optionally includes a 3rd digit in the pattern match for gust values. I also added a test, and made sure that I did not break any of the existing ones!