From e9ba7edfb90865d4138432c11a780fc2cf97c6fa Mon Sep 17 00:00:00 2001 From: Thomas Thrainer Date: Wed, 23 Apr 2014 09:25:58 +0200 Subject: [PATCH] Fix lint errors introduced during cherry-pick Calm a few lint errors introduced during cherry-picking code in qa_job_utils.py. The fixes were intentionally made in a way which should produce merge conflicts later on, so it's not forgotten to undo them. Signed-off-by: Thomas Thrainer Reviewed-by: Helga Velroyen --- qa/qa_job_utils.py | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/qa/qa_job_utils.py b/qa/qa_job_utils.py index 1c321d3..424d564 100644 --- a/qa/qa_job_utils.py +++ b/qa/qa_job_utils.py @@ -28,7 +28,8 @@ import sys import threading import time -from ganeti import constants +# (only used in later branches) +# from ganeti import constants from ganeti import locking from ganeti import utils from ganeti.utils import retry @@ -42,7 +43,10 @@ from qa_utils import AssertCommand, GetCommandOutput, GetObjectInfo AVAILABLE_LOCKS = [locking.LEVEL_NODE, ] -def _GetOutputFromMaster(cmd, use_multiplexer=True, log_cmd=True): +def _GetOutputFromMaster(cmd, + # pylint: disable=W0613 + # (only in later branches required) + use_multiplexer=True, log_cmd=True): """ Gets the output of a command executed on master. """ @@ -92,8 +96,9 @@ def _RetrieveTerminationInfo(job_id): if not execution_logs: return None + # ELOG_DELAY_TEST constant is only introduced in later branches is_termination_info_fn = \ - lambda e: e["Content"][1] == constants.ELOG_DELAY_TEST + lambda e: e["Content"][1] == "delay-test" # constants.ELOG_DELAY_TEST filtered_logs = filter(is_termination_info_fn, execution_logs) -- 1.7.10.4