diff --git a/clearml/backend_interface/task/repo/scriptinfo.py b/clearml/backend_interface/task/repo/scriptinfo.py index 20b47e78..30f2a850 100644 --- a/clearml/backend_interface/task/repo/scriptinfo.py +++ b/clearml/backend_interface/task/repo/scriptinfo.py @@ -1052,7 +1052,7 @@ class ScriptInfo(object): raise ScriptInfoError("Script file {} could not be found".format(filepaths)) - scripts_dir = [f.parent for f in scripts_path] + scripts_dir = [f if f.is_dir() else f.parent for f in scripts_path] def _log(msg, *args, **kwargs): if not log: