From fc6dfc6469137a82382a36b9469190d967593759 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20K=C3=B6ster?= Date: Mon, 2 May 2022 13:31:00 +0200 Subject: [PATCH] fix: multiext prefix computation in case it is used within a module that defines an additional prefix (#1609) --- snakemake/path_modifier.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/snakemake/path_modifier.py b/snakemake/path_modifier.py index 54c2dfaf6..9fa863e75 100644 --- a/snakemake/path_modifier.py +++ b/snakemake/path_modifier.py @@ -47,6 +47,10 @@ def modify(self, path, property=None): if not hasattr(modified_path, "flags"): modified_path = AnnotatedString(modified_path) modified_path.flags.update(path.flags) + if is_flagged(modified_path, "multiext"): + modified_path.flags["multiext"] = self.apply_default_remote( + self.replace_prefix(modified_path.flags["multiext"], property) + ) # Flag the path as modified and return. modified_path = flag(modified_path, PATH_MODIFIER_FLAG, self) return modified_path