From a0e862f083b31db240198e455120d2e99ded409c Mon Sep 17 00:00:00 2001 From: Christian Kellner Date: Fri, 15 Jan 2021 15:37:47 +0100 Subject: [PATCH] formats/v1: determine build_id outside param Instead of determining the build id while constructing the Pipeline object, do so beforehand. This makes it clearer what is going. --- osbuild/formats/v1.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/osbuild/formats/v1.py b/osbuild/formats/v1.py index 97fa5bef..3088176f 100644 --- a/osbuild/formats/v1.py +++ b/osbuild/formats/v1.py @@ -60,8 +60,8 @@ def load_pipeline(description: Dict, result: List[Pipeline]) -> Pipeline: else: build_pipeline, runner = None, detect_host_runner() - - pipeline = Pipeline(runner, build_pipeline and build_pipeline.tree_id) + build_id = build_pipeline and build_pipeline.tree_id + pipeline = Pipeline(runner, build_id) for s in description.get("stages", []): pipeline.add_stage(s["name"], s.get("options", {}))