From: Vasu Kulkarni Date: Sun, 10 Jun 2018 22:50:55 +0000 (-0700) Subject: need to debug why check_status is being ignored, for now catch X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=ad69ad69045e57f437c1373fbba9cccc08603ed9;p=teuthology.git need to debug why check_status is being ignored, for now catch the command failed error, log and ignore so that tests can pass. Signed-off-by: Vasu Kulkarni --- diff --git a/teuthology/task/internal/redhat.py b/teuthology/task/internal/redhat.py index 878d26b59..eac973491 100644 --- a/teuthology/task/internal/redhat.py +++ b/teuthology/task/internal/redhat.py @@ -9,6 +9,7 @@ from teuthology.config import config as teuthconfig from teuthology.parallel import parallel from teuthology.orchestra import run from teuthology.task.install.redhat import set_deb_repo +from teuthology.exceptions import CommandFailedError log = logging.getLogger(__name__) @@ -53,8 +54,12 @@ def _subscribe_stage_cdn(remote, teuthconfig): def _unsubscribe_stage_cdn(remote): - remote.run(args=['sudo', 'subscription-manager', 'unregister'], - check_status=False) + try: + remote.run(args=['sudo', 'subscription-manager', 'unregister'], + check_status=False) + except CommandFailedError: + # FIX ME + log.info("unregistring subscription-manager failed, ignoring") @contextlib.contextmanager