From 6672555aab2210fa2ea1e4abd798f3ec919f31f6 Mon Sep 17 00:00:00 2001 From: Oleg Smirnov Date: Sun, 16 Jun 2024 19:02:06 +0200 Subject: [PATCH] fixes #320 --- stimela/kitchen/step.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/stimela/kitchen/step.py b/stimela/kitchen/step.py index 19a3e45..7563d9b 100644 --- a/stimela/kitchen/step.py +++ b/stimela/kitchen/step.py @@ -422,8 +422,9 @@ def run(self, backend: Optional[Dict] = None, subst: Optional[Dict[str, Any]] = # Since prevalidation will have populated default values for potentially missing parameters, use those values # For parameters that aren't missing, use whatever value that was suplied - params = self.validated_params.copy() - params.update(**self.params) + # preserve order of specified params, to allow ordered substitutions to occur + params = self.params.copy() + params.update([(key, value) for key, value in self.validated_params.items() if key not in params]) skip_warned = False # becomes True when warnings are given