Added some logging to Sonarr/Radarr get_version.

pull/1509/head v0.9.7-beta.16
morpheus65535 3 years ago
parent 9c9e7de158
commit 83764bb07b

@ -261,6 +261,7 @@ class GetSonarrInfo:
except Exception: except Exception:
logging.debug('BAZARR cannot get Sonarr version') logging.debug('BAZARR cannot get Sonarr version')
sonarr_version = 'unknown' sonarr_version = 'unknown'
logging.debug('BAZARR got this Sonarr version from its API: {}'.format(sonarr_version))
region.set("sonarr_version", sonarr_version) region.set("sonarr_version", sonarr_version)
return sonarr_version return sonarr_version
@ -303,6 +304,7 @@ class GetRadarrInfo:
""" """
radarr_version = region.get("radarr_version", expiration_time=datetime.timedelta(seconds=60).total_seconds()) radarr_version = region.get("radarr_version", expiration_time=datetime.timedelta(seconds=60).total_seconds())
if radarr_version: if radarr_version:
region.set("radarr_version", radarr_version)
return radarr_version return radarr_version
else: else:
radarr_version = '' radarr_version = ''
@ -318,6 +320,7 @@ class GetRadarrInfo:
except Exception as e: except Exception as e:
logging.debug('BAZARR cannot get Radarr version') logging.debug('BAZARR cannot get Radarr version')
radarr_version = 'unknown' radarr_version = 'unknown'
logging.debug('BAZARR got this Radarr version from its API: {}'.format(radarr_version))
region.set("radarr_version", radarr_version) region.set("radarr_version", radarr_version)
return radarr_version return radarr_version

Loading…
Cancel
Save