From cc23f407afb8d78816dd8c124b0236cf9b8dd2ad Mon Sep 17 00:00:00 2001 From: "robin@ynput.io" Date: Wed, 4 Dec 2024 11:23:29 -0500 Subject: [PATCH] Address feedback from PR. --- client/ayon_core/pipeline/staging_dir.py | 11 ++++------- client/ayon_core/pipeline/tempdir.py | 6 ++---- 2 files changed, 6 insertions(+), 11 deletions(-) diff --git a/client/ayon_core/pipeline/staging_dir.py b/client/ayon_core/pipeline/staging_dir.py index 0317e55720..ea22d99389 100644 --- a/client/ayon_core/pipeline/staging_dir.py +++ b/client/ayon_core/pipeline/staging_dir.py @@ -173,13 +173,10 @@ def get_staging_dir_info( ) # add additional data - ctx_data.update({ - "product": { - "type": product_type, - "name": product_name - }, - "root": anatomy.roots - }) + ctx_data["product"] = { + "type": product_type, + "name": product_name + } # add additional template formatting data if template_data: diff --git a/client/ayon_core/pipeline/tempdir.py b/client/ayon_core/pipeline/tempdir.py index 52995d3f6a..fe057b7fc7 100644 --- a/client/ayon_core/pipeline/tempdir.py +++ b/client/ayon_core/pipeline/tempdir.py @@ -65,11 +65,9 @@ def _create_local_staging_dir(prefix, suffix, dirpath=None): str: path to tempdir """ # use pathlib for creating tempdir - staging_dir = Path(tempfile.mkdtemp( + return tempfile.mkdtemp( prefix=prefix, suffix=suffix, dir=dirpath - )) - - return staging_dir.as_posix() + ) def _create_custom_tempdir(project_name, anatomy):