From f3196d689980a66bc504348028d0ed4f30bfe220 Mon Sep 17 00:00:00 2001 From: Helga Velroyen Date: Wed, 21 Nov 2012 11:35:18 +0100 Subject: [PATCH] Fix lint error about too many variables Lint complains about too many variables in the CheckPrereq method. While I think that this method/class would need some refactoring in general, at least this patch makes lint shut up for now. Signed-off-by: Helga Velroyen Reviewed-by: Michele Tartara Signed-off-by: Iustin Pop --- lib/cmdlib.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/cmdlib.py b/lib/cmdlib.py index 29b527f..163baad 100644 --- a/lib/cmdlib.py +++ b/lib/cmdlib.py @@ -13346,11 +13346,11 @@ class LUInstanceSetParams(LogicalUnit): res_min = _ComputeIPolicyInstanceSpecViolation(ipolicy, ispec_min) if (res_max or res_min): - res = set(res_max + res_min) # FIXME: Improve error message by including information about whether # the upper or lower limit of the parameter fails the ipolicy. msg = ("Instance allocation to group %s (%s) violates policy: %s" % - (group_info, group_info.name, utils.CommaJoin(res))) + (group_info, group_info.name, + utils.CommaJoin(set(res_max + res_min)))) raise errors.OpPrereqError(msg, errors.ECODE_INVAL) def _ConvertPlainToDrbd(self, feedback_fn): -- 1.7.10.4