From 582f202b5031f91cf7270e8423fc6a55ceae3803 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ricardo=20Ca=C3=B1uelo?= Date: Fri, 12 Jan 2024 11:11:25 +0100 Subject: [PATCH] config/runtime/kunit: fix artifact field names MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Normalize field names, replace '.' characters with '_', as dots in fields are problematic with mongodb Signed-off-by: Ricardo CaƱuelo --- config/runtime/kunit.jinja2 | 2 ++ 1 file changed, 2 insertions(+) diff --git a/config/runtime/kunit.jinja2 b/config/runtime/kunit.jinja2 index 2e11381ef..7cd6d0c05 100644 --- a/config/runtime/kunit.jinja2 +++ b/config/runtime/kunit.jinja2 @@ -68,6 +68,8 @@ cd {src_path} root_path = '-'.join([JOB_NAME, NODE['id']]) print(f"Uploading artifacts to {root_path}") for file_name, file_path in local_artifacts.items(): + # Normalize field names + file_name = file_name.replace('.', '_') if os.path.exists(file_path): file_url = storage.upload_single( (file_path, file_name), root_path