Skip to content
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

Cannot get skill to work #1

Open
blissb opened this issue Feb 21, 2022 · 3 comments
Open

Cannot get skill to work #1

blissb opened this issue Feb 21, 2022 · 3 comments

Comments

@blissb
Copy link

blissb commented Feb 21, 2022

I'm wondering if this skill is still being maintained -- I see there have been no updates in 16 months.

The skill installs, and appears to be parsing through the data returned from NOAA, but I cannot get it to work -- only "no alerts for your area." Yesterday, there were several severe weather alerts for my area, I could see them in the data from NOAA, but still "no alerts."

I have tried using the "Mycroft device" and Geo-Code options - to no avail. If I try to pull only the data for my region, the skill completely breaks.

@domcross
Copy link
Owner

Hi @blissb
You are the first in more than two years who tried the skill a gives some feedback back. Are you willing to share your geocode/location data so I can have a look?

@domcross
Copy link
Owner

A quick test with US-service and geo-location "AKZ214" (and urgency "future", severity "minor", certainty "possible" to get any available alert) gives me five alerts (as of 2022-02-21 11:30 CET).

The device-location settings does not work with all services.
You can look up the UGC geocode from the zone-list of your state here: https://alerts.weather.gov (e.g. Alaska, Yukon Delta is AKZ214)

I will have a look if there is a library or online service that maps long/lat coordinates to geocodes...

@blissb
Copy link
Author

blissb commented Mar 1, 2022

Sorry for the delay in getting back to you, and thank you for the response.

I think I see the problem -- I was using the county code (VTC023), not the zone code (VTZ008).

What I ended up doing was forking the project and editing swi_resources.py by replacing the US1 url with the url for the RSS feed for my specific county (https://alerts.weather.gov/cap/wwaatmget.php?x=VTC023&y=0), and then setting the location filter to "none." This works as expected and returns very quickly, too, since it doesn't have to parse through and filter out the rest of the national data.

Now that I know what I was doing wrong, I'm going to restore the original version and try it again.

[updated]

Apparently I'm still doing something wrong, but I cannot see what it is. I uninstalled my fork, checked to make sure it was actually gone (it was). Rebooted. Installed the original version. Configured it using the VTZ008 zone code. Asked for alerts and was given a bunch of flood warnings for Alabama.

I tried using the custom configuration and custom url -- that said there was an error in the module.

I've re-installed the fork, and have it working again.

After getting the error message when using a custom URL, I noticed in the swi_resources the "ZZZ" line was different than the US lines.
'ZZZ:zz': {'country': 'ZZ', 'lang': 'zz', 'title': 'Custom configuration', 'url': 'custom', 'hdr_feed': '', 'hdr_atom': ''}

I changed it to read:

'ZZZ:zz': {'country': 'ZZ', 'lang': 'zz', 'title': 'Custom configuration', 'url': 'custom', hdr_feed': {'Accept': 'application/atom+xml'}, 'hdr_atom': {'Accept': 'application/cap+xml'}}

With that change I was able to put the county RSS URL (same as above) in to the "custom URL" field and have it return without error.

Since I seem to be the only one having an issue, and since I have a work-around, this is not terribly important -- however, if I can do any more testing/breaking, please let me know!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants