From 89fee277e30f50de1d6fe8ee56ed4ea2cabb1796 Mon Sep 17 00:00:00 2001 From: DominikDoom Date: Tue, 9 Sep 2025 10:04:00 +0200 Subject: [PATCH] Fix model path breaking with commas in filenames Fixes #332 --- scripts/tag_autocomplete_helper.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/tag_autocomplete_helper.py b/scripts/tag_autocomplete_helper.py index 77945ee..30aefbb 100644 --- a/scripts/tag_autocomplete_helper.py +++ b/scripts/tag_autocomplete_helper.py @@ -98,9 +98,9 @@ def sort_models(model_list, sort_method = None, name_has_subpath = False): # During merging on the JS side we need to re-sort anyway, so here only the sort criteria are calculated. # The list itself doesn't need to get sorted at this point. if len(model_list[0]) > 2: - results = [f'{name},"{sorter(path, name, name_has_subpath)}",{meta}' for path, name, meta in model_list] + results = [f'"{name}","{sorter(path, name, name_has_subpath)}",{meta}' for path, name, meta in model_list] else: - results = [f'{name},"{sorter(path, name, name_has_subpath)}"' for path, name in model_list] + results = [f'"{name}","{sorter(path, name, name_has_subpath)}"' for path, name in model_list] return results