-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Updated alerts not removed #8
Comments
I'm not sure I follow. I haven't had any issues with expired events not being removed. Maybe it was a glitch in the NWS system? they have a few of those fairly often. As far as I know (unless they have changed something) every new or update to an alert should generate a new event id. So you should be able to figure out if there is an update by looking at the event id. Or maybe I've just never noticed and it's never been mentioned before. However, I have seen alert updates and they have come thru as new alerts. So I think it's working as expected. but there is also no way for the integration to know if it's an update to a previously issued alert or if it's a completely new alert since they both (should...) get new event ids. |
To clarify, when an update to an alert is published, new_alerts is adding it as if it is a new alert. I originally had one flooding advisory and one wind advisory. When weather.gov updated the wind advisory, nws_alerts now showed three total alerts. However, when I looked at weather.gov and DarkSky it correctly displayed only two active alerts. I understand that each alert is given a unique ID, however the number of active alerts should match weather.gov. Perhaps DarkSky pulls the alerts when they receive an update. |
I've never had that issue so I'm not sure how I could replicate it to troubleshoot it. were all three of them all within the "expires" or "ends" timeframe? Was this a one time thing or has it happened multiple times? |
I'm getting this same issue currently. From what I can tell there was an updated warning still in effect with an "expiredReferences" noted on the updated warning. Here is the raw json event ID:
Here is the original event link and the updated link. The relevant data from the updated warning raw json:
|
I haven't had multiple alerts since. Two were almost identical. Reading the second alert I could tell it was just updated. I'll be sure to copy the entire alert entity value next time. |
Also, can someone post the entity value of their NWS alert when it has multiple alerts. It could be added to the readme for the purpose of testing. |
I'm really sorry guys. It's going to be so hard to troubleshoot this since it's not reproducible at all on my end and the issue conditions seem to happen so rarely. I'm going to try to get some clarifying info so please don't feel I'm being condescending:
https://api.weather.gov/alerts/active?zone=
|
No problem whatever helps.
|
I believe I may be currently experiencing this issue. Currently, the entity is showing a value of 2. When I lookup my county on the alerts site, there is only 1 alert:
Clicking on the link in the alert directs me to this message
This is what the API is returning for my county:
Here is the attributes content as well:
|
Thanks @jojeda654 for all of that information. from all of that it definitely looks like a glitch in the NWS API. The only thing the integration does is looks at the number of events reported in the data returned by the API. And from the info above there actually two events in the API call. And that info is updated every minute. How the county active alert counts and the data provided by the API are cross-referenced I have no idea about. It seems like a situation where one hand doesn't fully know what the other is doing. So with that I'm not sure there is much I can do about it. I think the important thing is that the new alerts actually pop up when expected and the old alerts do eventually get removed when the API gets updated information. |
I just added a new attribute for the sensor called "message type". I don't know if it will help you out or not but you should be able to filter on that message type for "update" or something along those lines. |
Issue: Updated alerts are no removed. I have three active while weather.gov is only showing two (as is dark sky)
Reproduction: When an alert is updated it should show as a new alert. I did a diff on both alerts and found a few minor changes.
Expected Result: When an alert is updated, the number of alerts should remain the same. The entity is updated which can be used to trigger automatons for weather alert updates (instead of new weather alerts).
Side note: Thanks for the integration. I needed something with alerts to replace DarkSky for when the API is no longer free.
The text was updated successfully, but these errors were encountered: