From 107779f45a788b0e9d992f658ec1c15da6cfb0bb Mon Sep 17 00:00:00 2001 From: allegroai <> Date: Fri, 15 Jul 2022 16:20:46 +0300 Subject: [PATCH] Fix only preview filename and not full path when uploading a single artifact file --- clearml/binding/artifacts.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clearml/binding/artifacts.py b/clearml/binding/artifacts.py index bbab5533..d9812306 100644 --- a/clearml/binding/artifacts.py +++ b/clearml/binding/artifacts.py @@ -588,7 +588,7 @@ class Artifacts(object): override_filename_in_uri = artifact_object.parts[-1] artifact_type_data.preview = preview or '{} - {}\n'.format( - artifact_object, format_size(artifact_object.stat().st_size)) + artifact_object.name, format_size(artifact_object.stat().st_size)) artifact_object = artifact_object.as_posix() artifact_type = 'custom' artifact_type_data.content_type = mimetypes.guess_type(artifact_object)[0]