From: kaliko Date: Fri, 23 Oct 2020 18:30:03 +0000 (+0200) Subject: feeds: catch ConnectionError to avoid killing thread X-Git-Tag: 0.2.0~3 X-Git-Url: https://git.kaliko.me/?a=commitdiff_plain;h=5fa1621bb067968bef83cdd8eb4e9b7a98b60b66;p=sid.git feeds: catch ConnectionError to avoid killing thread --- diff --git a/sid/feeds.py b/sid/feeds.py index 7fe5825..490d89d 100644 --- a/sid/feeds.py +++ b/sid/feeds.py @@ -124,6 +124,8 @@ class FeedMonitor(threading.Thread): for feed in self.feeds_list: try: self.new_posts(feed) + except ConnectionError as err: # Non fatal exception + self.plugin.log.error(f'connection error on {feed}: {err}') except URLError as err: # Non fatal exception self.plugin.log.error(f'error for {feed}: {err.reason}') except Exception as err: # Unknown execption, killing thread anyway