From ccaba9340bc9177b35b5eca05d4d651faabf21e1 Mon Sep 17 00:00:00 2001 From: MustafaJafar Date: Mon, 22 Apr 2024 15:20:03 +0200 Subject: [PATCH] update comments --- .../publish/collect_files_for_cleaning_up.py | 26 +++++++++---------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/client/ayon_core/hosts/houdini/plugins/publish/collect_files_for_cleaning_up.py b/client/ayon_core/hosts/houdini/plugins/publish/collect_files_for_cleaning_up.py index 3356c6bd0d..e170dce4e0 100644 --- a/client/ayon_core/hosts/houdini/plugins/publish/collect_files_for_cleaning_up.py +++ b/client/ayon_core/hosts/houdini/plugins/publish/collect_files_for_cleaning_up.py @@ -8,7 +8,7 @@ from ayon_core.hosts.houdini.api import lib class CollectFilesForCleaningUp(pyblish.api.InstancePlugin, AYONPyblishPluginMixin): """Collect Files For Cleaning Up. - + This collector collects output files and adds them to file remove list. @@ -45,20 +45,20 @@ class CollectFilesForCleaningUp(pyblish.api.InstancePlugin, if not node: self.log.debug("Skipping Collector. Instance has no instance_node") return - + output_parm = lib.get_output_parameter(node) if not output_parm: self.log.debug("ROP node type '{}' is not supported for cleaning up." .format(node.type().name())) return - + filepath = output_parm.eval() if not filepath: self.log.warning("No filepath value to collect.") return files = [] - # Non Render Products with frames + # Products with frames frames = instance.data.get("frames", []) staging_dir, _ = os.path.split(filepath) if isinstance(frames, str): @@ -66,7 +66,7 @@ class CollectFilesForCleaningUp(pyblish.api.InstancePlugin, else: files = [os.path.join(staging_dir, f) for f in frames] - # Render Products + # Farm Products with expected files expectedFiles = instance.data.get("expectedFiles", []) for aovs in expectedFiles: # aovs.values() is a list of lists @@ -74,7 +74,7 @@ class CollectFilesForCleaningUp(pyblish.api.InstancePlugin, # Intermediate exported render files. # TODO : For products like Karma, - # Karma has more intermediate files + # Karma has more intermediate files # e.g. USD and checkpoint ifdFile = instance.data.get("ifdFile") if self.intermediate_exported_render and ifdFile: @@ -84,14 +84,14 @@ class CollectFilesForCleaningUp(pyblish.api.InstancePlugin, ifd_files = self._get_ifd_file_list(ifdFile, start_frame, end_frame) files.extend(ifd_files) - - # Non Render Products with no frames + + # Products with single output file/frame if not files: files.append(filepath) self.log.debug("Add directories to 'cleanupEmptyDir': {}".format(staging_dir)) instance.context.data["cleanupEmptyDirs"].append(staging_dir) - + self.log.debug("Add files to 'cleanupFullPaths': {}".format(files)) instance.context.data["cleanupFullPaths"] += files @@ -113,10 +113,10 @@ class CollectFilesForCleaningUp(pyblish.api.InstancePlugin, match, int(start_frame), int(end_frame) ) result = [ - os.path.join(parent_path, r).replace("\\", "/") + os.path.join(parent_path, r).replace("\\", "/") for r in result ] - return result - - return [] \ No newline at end of file + return result + + return []