mirror of
https://git.ianrenton.com/ian/spothole.git
synced 2025-10-27 08:49:27 +00:00
Finish support for WOTA #63
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
import re
|
||||
from datetime import datetime
|
||||
|
||||
import pytz
|
||||
@@ -23,6 +22,11 @@ class WOTA(HTTPAlertProvider):
|
||||
rss = RSSParser.parse(http_response.content.decode())
|
||||
# Iterate through source data
|
||||
for source_alert in rss.channel.items:
|
||||
|
||||
# Reject GUID missing or zero
|
||||
if not source_alert.guid or not source_alert.guid.content or source_alert.guid.content == "http://www.wota.org.uk/alerts/0":
|
||||
continue
|
||||
|
||||
# Pick apart the title
|
||||
title_split = source_alert.title.split(" on ")
|
||||
dx_call = title_split[0]
|
||||
|
||||
Reference in New Issue
Block a user