Removed unecessary exception and replaced with a logging error.

pull/3818/head
Anna Bridge 2017-02-23 19:02:55 +00:00
parent e95092c91a
commit 415486e780
1 changed files with 2 additions and 1 deletions

View File

@ -116,7 +116,8 @@ def invoke_api(payload, url, auth, polls, begin="start/"):
logging.debug(r.request.body)
if r.status_code != 200:
raise Exception("Error while talking to the mbed API")
logging.error("HTTP code %d reported.", r.status_code)
return False, "Internal"
response = r.json()
logging.debug(response)