Commit 9c4f4dd6 authored by Michael Hanselmann's avatar Michael Hanselmann
Browse files

Fix pylint warning on unreachable code

Commit c50452c3

 added an exception when all instances should be
evacuated off a node, but did so in a way which made pylint complain
about unreachable code.
Signed-off-by: default avatarMichael Hanselmann <>
Reviewed-by: default avatarIustin Pop <>
parent c50452c3
......@@ -10148,6 +10148,7 @@ class LUNodeEvacuate(NoHooksLU):
# All instances
assert self.op.mode == constants.IALLOCATOR_NEVAC_ALL
inst_fn = _GetNodeInstances
# TODO: In 2.6, change the iallocator interface to take an evacuation mode
# per instance
raise errors.OpPrereqError("Due to an issue with the iallocator"
......@@ -10156,7 +10157,6 @@ class LUNodeEvacuate(NoHooksLU):
" whether to evacuate primary or secondary"
" instances",
inst_fn = _GetNodeInstances
return inst_fn(self.cfg, self.op.node_name)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment