avwx-rest / avwx-api

REST API for parsing aviation weather data
https://avwx.rest
MIT License
71 stars 89 forks source link

TAF and ?onfail=nearest #33

Open boozedog opened 11 months ago

boozedog commented 11 months ago

I was hoping that using ?onfail=nearest would return closest airport that reports TAFs. But I think it just returns the closest airport that reports anything including METARs. Is that expected behavior?

devdupont commented 6 months ago

That is the intended behavior right now. The nearest naively looks for a flag on the station graph. I would be possible to make this check subsequent stations until a TAF is able to be fetched, though it would noticeably increase response times. A valid report is better than nothing?