diff --git a/couchpotato/core/downloaders/rtorrent/main.py b/couchpotato/core/downloaders/rtorrent/main.py index a35cb006..563e3bb7 100755 --- a/couchpotato/core/downloaders/rtorrent/main.py +++ b/couchpotato/core/downloaders/rtorrent/main.py @@ -19,6 +19,7 @@ class rTorrent(Downloader): protocol = ['torrent', 'torrent_magnet'] rt = None testable = True + error_msg = '' # Migration url to host options def __init__(self): @@ -54,15 +55,23 @@ class rTorrent(Downloader): else: self.rt = RTorrent(url) - if not self.rt.test_connection(): - self.rt = None + self.error_msg = '' + try: + self.rt._verify_conn() + except AssertionError as e: + self.error_msg = e.message + self.rt = None return self.rt def test(self): - if not self.connect(True): - return False - return True + if self.connect(True): + return True + + if self.error_msg: + return False, 'Connection failed: ' + self.error_msg + + return False def _update_provider_group(self, name, data): if data.get('seed_time'): diff --git a/couchpotato/core/downloaders/sabnzbd/main.py b/couchpotato/core/downloaders/sabnzbd/main.py index b6ef7f21..9eea8c9a 100644 --- a/couchpotato/core/downloaders/sabnzbd/main.py +++ b/couchpotato/core/downloaders/sabnzbd/main.py @@ -26,6 +26,7 @@ class Sabnzbd(Downloader): if int(v[0]) == 0 and int(v[1]) < 7: return False, 'Your Sabnzbd client is too old, please update to newest version.' + # the version check will work even with wrong api key, so we need the next check as well sab_data = self.call({ 'mode': 'qstatus', })