From 8bcc4a3939d4e52cce731a0e712b87b283fee37d Mon Sep 17 00:00:00 2001 From: Jakub Trllo <43494761+iLLiCiTiT@users.noreply.github.com> Date: Fri, 1 Aug 2025 18:23:15 +0200 Subject: [PATCH] Make sure workdir exists when workfile is being saved --- client/ayon_core/host/interfaces/workfiles.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/client/ayon_core/host/interfaces/workfiles.py b/client/ayon_core/host/interfaces/workfiles.py index b519751ba2..82d71d152a 100644 --- a/client/ayon_core/host/interfaces/workfiles.py +++ b/client/ayon_core/host/interfaces/workfiles.py @@ -944,6 +944,8 @@ class IWorkfileHost: self._emit_workfile_save_event(event_data, after_save=False) workdir = os.path.dirname(filepath) + if not os.path.exists(workdir): + os.makedirs(workdir, exist_ok=True) # Set 'AYON_WORKDIR' environment variable os.environ["AYON_WORKDIR"] = workdir