From: Zack Cerza Date: Wed, 29 Mar 2017 19:38:37 +0000 (-0600) Subject: DaemonState: Catch CommandFailedError during stop X-Git-Tag: 1.1.0~437^2 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=28a301535247c43c55247c21785907af7c5cefd8;p=teuthology.git DaemonState: Catch CommandFailedError during stop So that job teardown isn't hindered. Signed-off-by: Zack Cerza --- diff --git a/teuthology/orchestra/daemon.py b/teuthology/orchestra/daemon.py index df2cf3f6cc..18f873f374 100644 --- a/teuthology/orchestra/daemon.py +++ b/teuthology/orchestra/daemon.py @@ -3,6 +3,7 @@ import struct from . import run from .. import misc +from teuthology.exceptions import CommandFailedError log = logging.getLogger(__name__) @@ -43,7 +44,10 @@ class DaemonState(object): return self.proc.stdin.close() self.log.debug('waiting for process to exit') - run.wait([self.proc], timeout=timeout) + try: + run.wait([self.proc], timeout=timeout) + except CommandFailedError: + log.exception("Error while waiting for process to exit") self.proc = None self.log.info('Stopped')