exc_info need to be in an except block

This commit is contained in:
jesopo 2019-06-27 16:00:14 +01:00
parent e30ae803b0
commit 14b7a8ae11

View file

@ -38,13 +38,11 @@ class Module(ModuleManager.BaseModule):
try:
data = utils.http.request(url)
feed = feedparser.parse(data.data)
feed["feed"] or ValueError("Feed info empty")
except:
feed = None
if not feed or not feed["feed"]:
self.log.warn("Failed to parse rss for %s", [url],
self.log.warn("Failed to GET RSS for %s", [url],
exc_info=True)
continue
return
feed_title = feed["feed"]["title"]
entry_formatted = {}