Commit 9bc5ac44 authored by René Nussbaumer's avatar René Nussbaumer
Browse files

Provide a custom Validate for OpInstanceMultiAlloc

This is needed, as we're not strictly separating validation from
populating the defaults. We do this all in one function. If we now
receive a non complete OpInstanceCreate opcode in instances, we would
run into AttributeErrors on those.

So we run the validation + recursively on all instances opcodes.
Signed-off-by: default avatarRené Nussbaumer <>
Reviewed-by: default avatarIustin Pop <>
parent 2958c56e
......@@ -1256,6 +1256,17 @@ class OpInstanceMultiAlloc(OpCode):
state["instances"] = insts
return OpCode.__setstate__(self, state)
def Validate(self, set_defaults):
"""Validates this opcode.
We do this recursively.
OpCode.Validate(self, set_defaults)
for inst in self.instances:
class OpInstanceReinstall(OpCode):
"""Reinstall an instance's OS."""
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