From: Zack Cerza Date: Fri, 8 Nov 2013 00:39:16 +0000 (-0600) Subject: Also catch socket.error in try_push_job_info X-Git-Tag: 1.1.0~1778 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=b3e730e3467740c2139bba470fdd5b158cb41084;p=teuthology.git Also catch socket.error in try_push_job_info --- diff --git a/teuthology/report.py b/teuthology/report.py index a67a1dcca..b1c0a78a0 100644 --- a/teuthology/report.py +++ b/teuthology/report.py @@ -5,6 +5,7 @@ import re import httplib2 import urllib import logging +import socket import teuthology from teuthology.config import config @@ -365,6 +366,7 @@ def try_push_job_info(job_config, extra_info=None): """ Wrap push_job_info, gracefully doing nothing if: A RequestFailedError is raised + A socket.error is raised config.results_server is not set config['job_id'] is not present or is None @@ -391,6 +393,6 @@ def try_push_job_info(job_config, extra_info=None): try: log.info("Pushing job info to %s", config.results_server) push_job_info(run_name, job_id, job_info) - except RequestFailedError: + except (RequestFailedError, socket.error): log.exception("Could not report results to %s" % config.results_server)