From 4adc37dcdcb899d9bd7d702b3aca39ffa70ae494 Mon Sep 17 00:00:00 2001 From: Zack Cerza Date: Tue, 24 May 2016 17:12:23 -0600 Subject: [PATCH] Move MaxWhileTries to the exceptions module Signed-off-by: Zack Cerza --- teuthology/contextutil.py | 6 ++---- teuthology/exceptions.py | 4 ++++ 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/teuthology/contextutil.py b/teuthology/contextutil.py index c3ae7fe1d8..be9800301a 100644 --- a/teuthology/contextutil.py +++ b/teuthology/contextutil.py @@ -3,7 +3,9 @@ import sys import logging import time import itertools + from .config import config +from .exceptions import MaxWhileTries log = logging.getLogger(__name__) @@ -52,10 +54,6 @@ def nested(*managers): raise exc[0], exc[1], exc[2] -class MaxWhileTries(Exception): - pass - - class safe_while(object): """ A context manager to remove boiler plate code that deals with `while` loops diff --git a/teuthology/exceptions.py b/teuthology/exceptions.py index c12700d92f..c3dbbde780 100644 --- a/teuthology/exceptions.py +++ b/teuthology/exceptions.py @@ -154,3 +154,7 @@ class SkipJob(Exception): be skipped. """ pass + + +class MaxWhileTries(Exception): + pass -- 2.39.5