zaskem / slackbot-tempestweather

A Slack bot to interact with a Tempest weather station, bringing local weather data into your favorite Slack channels.
GNU General Public License v3.0
0 stars 0 forks source link

NWS API & Urgency Values #84

Open zaskem opened 2 years ago

zaskem commented 2 years ago

There is some wonky behavior with regard to active alerts from the NWS API. When using the default values from config/nws.php.example ('Immediate,Expected,Future,Unknown') cancelled alerts may still show up until the original alert expiration date has passed. Dropping the Future alert option solves this problem but fails to then identify non-severe (e.g. 'watch') alerts.

Dropping the urgency parameter from the API call seems to address this issue entirely; more testing is necessary to verify. If so, dropping or modifying how the urgency parameter is handled (e.g. allow the bot host control over whether or not to use it) would be a reasonable idea.