aeharding / metar-taf-parser

Parser for METeorological Aerodrome Reports (METARs) and Terminal Aerodrome Forecasts (TAFs) in Typescript
https://aeharding.github.io/metar-taf-parser
MIT License
40 stars 9 forks source link

CommandExecutionError: 0 not found in /,1,2,5,9 #96

Closed daniluk4000 closed 6 months ago

daniluk4000 commented 6 months ago

Gettings this error when trying to parse this METAR

UUWW 151030Z 34002MPS CAVOK 14/02 Q1026 R01/000070 NOSIG

Also reproducable in your demo

aeharding commented 6 months ago

Hi! This is because R01/000070 is invalid. However it should probably not fail completely.

daniluk4000 commented 6 months ago

This is sadly "official" METAR from https://tgftp.nws.noaa.gov/data/observations/metar/stations/UUWW.TXT

aeharding commented 6 months ago

Can you review #97 and let me know if that would work for you? Thanks!

daniluk4000 commented 6 months ago

Can you review #97 and let me know if that would work for you? Thanks!

I trust tests :)

Thank you for this quick fix!

aeharding commented 6 months ago

Should be working on 9.0.1! Thanks for reporting.

https://aeharding.github.io/metar-taf-parser/metar?input=UUWW+151030Z+34002MPS+CAVOK+14%2F02+Q1026+R01%2F000070+NOSIG