From 87189c44e8989f8288984a9c740af7eec29dc2be Mon Sep 17 00:00:00 2001 From: Valentin Berlier Date: Mon, 22 Jul 2024 02:56:56 +0200 Subject: [PATCH] fix: match default vanilla release without patch --- beet/contrib/vanilla.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/beet/contrib/vanilla.py b/beet/contrib/vanilla.py index 3365266f..9c12d9ed 100644 --- a/beet/contrib/vanilla.py +++ b/beet/contrib/vanilla.py @@ -211,7 +211,14 @@ def __init__( self.manifest = manifest def missing(self, key: str) -> Release: - pattern = re.compile("^" + r"\d+".join(map(re.escape, key.split("*"))) + "$") + pattern = re.compile( + "^" + "|".join( + r"\d+".join(map(re.escape, k.split("*"))) + for k in {key, key.removesuffix(".*")} + ) + + "$" + ) for version in self.manifest.data["versions"]: if pattern.match(version["id"]): info = JsonFile(source_path=self.cache.download(version["url"]))