mirror of
https://github.com/clinton-hall/nzbToMedia.git
synced 2025-08-21 05:43:16 -07:00
add more logging to server tests. #1113
This commit is contained in:
parent
92c356a6b0
commit
6bfb0f4a53
1 changed files with 3 additions and 0 deletions
|
@ -1148,10 +1148,13 @@ def import_subs(filename):
|
||||||
|
|
||||||
|
|
||||||
def server_responding(baseURL):
|
def server_responding(baseURL):
|
||||||
|
logger.debug("Attempting to connect to server at {0}".format(baseURL), 'SERVER')
|
||||||
try:
|
try:
|
||||||
requests.get(baseURL, timeout=(60, 120), verify=False)
|
requests.get(baseURL, timeout=(60, 120), verify=False)
|
||||||
|
logger.debug("Server responded at {0}".format(baseURL), 'SERVER')
|
||||||
return True
|
return True
|
||||||
except (requests.ConnectionError, requests.exceptions.Timeout):
|
except (requests.ConnectionError, requests.exceptions.Timeout):
|
||||||
|
logger.error("Server failed to responded at {0}".format(baseURL), 'SERVER')
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue