From d572e5210d40826fe7285a367f24c5029a45de91 Mon Sep 17 00:00:00 2001 From: Sergei Trofimov Date: Thu, 29 Mar 2018 17:54:04 +0100 Subject: [PATCH] fw/config: ensure boot/runtime_params are initialized Ensure that boot and runtime parameters always get initialized to an obj_dict even when not explicitly specified. This will ensure they get serialized and deserialized properly. --- wa/framework/configuration/core.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/wa/framework/configuration/core.py b/wa/framework/configuration/core.py index 3a7a2f92..8581cf5b 100644 --- a/wa/framework/configuration/core.py +++ b/wa/framework/configuration/core.py @@ -794,6 +794,10 @@ class JobSpec(Configuration): self.to_merge = defaultdict(OrderedDict) self._sources = [] self.id = None + if self.boot_parameters is None: + self.boot_parameters = obj_dict() + if self.runtime_parameters is None: + self.runtime_parameters = obj_dict() def to_pod(self): pod = super(JobSpec, self).to_pod()