From 3a5465371114627377a6ac03817dde05f16bd2a0 Mon Sep 17 00:00:00 2001 From: Fabian Neumann Date: Fri, 15 Mar 2024 13:50:27 +0100 Subject: [PATCH] fix shared resources for scenario management with {kind} wildcard --- scripts/_helpers.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/_helpers.py b/scripts/_helpers.py index 09687a11..d03a306b 100644 --- a/scripts/_helpers.py +++ b/scripts/_helpers.py @@ -60,7 +60,7 @@ def get_run_path(fn, dir, rdir, shared_resources): if shared_resources == "base": pattern = r"\{([^{}]+)\}" existing_wildcards = set(re.findall(pattern, fn)) - irrelevant_wildcards = {"technology", "year", "scope"} + irrelevant_wildcards = {"technology", "year", "scope", "kind"} no_relevant_wildcards = not existing_wildcards - irrelevant_wildcards no_elec_rule = not fn.startswith("networks/elec") and not fn.startswith( "add_electricity" @@ -68,7 +68,7 @@ def get_run_path(fn, dir, rdir, shared_resources): is_shared = no_relevant_wildcards and no_elec_rule elif isinstance(shared_resources, str): rdir = shared_resources + "/" - is_shared = True + is_shared = False elif isinstance(shared_resources, bool): is_shared = shared_resources else: