Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions metar/Metar.py
Original file line number Diff line number Diff line change
Expand Up @@ -1050,6 +1050,8 @@ def _unparsedRemark(self, d):
(RUNWAY_RE, _handleRunway, True),
(WEATHER_RE, _handleWeather, True),
(SKY_RE, _handleSky, True),
(WIND_RE, _handleWind, False),
(VISIBILITY_RE, _handleVisibility, True),
(TEMP_RE, _handleTemp, False),
(PRESS_RE, _handlePressure, True),
(RECENT_RE, _handleRecent, True),
Expand Down
13 changes: 13 additions & 0 deletions test/test_metar.py
Original file line number Diff line number Diff line change
Expand Up @@ -654,6 +654,19 @@ def test_cor_auto_mod():

assert m.mod == 'COR AUTO'

def test_wind_after_sky():
"""
Test parsing of a METAR that lists wind after the sky groups
"""

code = (
"METAR KCOF 281855Z FEW029TCU FEW040 SCT250 09008KT 7SM 32/25 A3008 "
"RMK VIRGA E TCU NE AND DSNT ALQDS SLP186"
)
m = Metar.Metar(code, year=2007)

assert m.wind_dir.value() == 90
assert m.wind_speed.value() == 8

def test_issue136_temperature():
raisesParserError("METAR EDDM 022150Z 26006KT CAVOK 201/16")