diff --git a/client/ayon_core/hosts/photoshop/api/launch_logic.py b/client/ayon_core/hosts/photoshop/api/launch_logic.py index ccb7b0048b..9c6a1e8a01 100644 --- a/client/ayon_core/hosts/photoshop/api/launch_logic.py +++ b/client/ayon_core/hosts/photoshop/api/launch_logic.py @@ -397,9 +397,10 @@ class PhotoshopRoute(WebSocketRoute): # Define saving file extension extensions = host.get_workfile_extensions() - work_root = work_template["directory"].format_strict(data) + work_root = str(work_template["directory"].format_strict(data)) + file_template = str(work_template["file"]) last_workfile_path = get_last_workfile( - work_root, work_template["file"], data, extensions, True + work_root, file_template, data, extensions, True ) return last_workfile_path diff --git a/client/ayon_core/hosts/tvpaint/plugins/load/load_workfile.py b/client/ayon_core/hosts/tvpaint/plugins/load/load_workfile.py index 16cb54f4a3..0b6d67a840 100644 --- a/client/ayon_core/hosts/tvpaint/plugins/load/load_workfile.py +++ b/client/ayon_core/hosts/tvpaint/plugins/load/load_workfile.py @@ -93,9 +93,9 @@ class LoadWorkfile(plugin.Loader): data["ext"] = extension.lstrip(".") - work_root = work_template["directory"].format_strict(data) + work_root = str(work_template["directory"].format_strict(data)) version = get_last_workfile_with_version( - work_root, work_template["file"], data, extensions + work_root, str(work_template["file"]), data, extensions )[1] if version is None: diff --git a/client/ayon_core/lib/applications.py b/client/ayon_core/lib/applications.py index c4f1d168b5..123396f5f6 100644 --- a/client/ayon_core/lib/applications.py +++ b/client/ayon_core/lib/applications.py @@ -1862,7 +1862,9 @@ def _prepare_last_workfile(data, workdir, addons_manager): project_settings=project_settings ) # Find last workfile - file_template = anatomy.get_template("work", template_key, "file") + file_template = str( + anatomy.get_template("work", template_key, "file") + ) workdir_data.update({ "version": 1, diff --git a/client/ayon_core/tools/workfiles/models/workfiles.py b/client/ayon_core/tools/workfiles/models/workfiles.py index f4ca08a45a..ef502e3d6f 100644 --- a/client/ayon_core/tools/workfiles/models/workfiles.py +++ b/client/ayon_core/tools/workfiles/models/workfiles.py @@ -200,7 +200,7 @@ class WorkareaModel: self, workdir, file_template, fill_data, extensions ): version = get_last_workfile_with_version( - workdir, str(file_template), fill_data, extensions + workdir, file_template, fill_data, extensions )[1] if version is None: @@ -300,7 +300,9 @@ class WorkareaModel: workdir = self._get_workdir(anatomy, template_key, fill_data) - file_template = anatomy.get_template("work", template_key, "file") + file_template = str( + anatomy.get_template("work", template_key, "file") + ) comment_hints, comment = self._get_comments_from_root( file_template,