diff --git a/pype/plugins/global/publish/submit_publish_job.py b/pype/plugins/global/publish/submit_publish_job.py index 097761cf4e..444ad28b6c 100644 --- a/pype/plugins/global/publish/submit_publish_job.py +++ b/pype/plugins/global/publish/submit_publish_job.py @@ -151,6 +151,7 @@ class ProcessSubmittedJobOnFarm(pyblish.api.InstancePlugin): deadline_pool_secondary = "" deadline_group = "" deadline_chunk_size = 1 + deadline_priority = None # regex for finding frame number in string R_FRAME_NUMBER = re.compile(r'.+\.(?P[0-9]+)\..+') @@ -902,7 +903,11 @@ class ProcessSubmittedJobOnFarm(pyblish.api.InstancePlugin): render_job["Props"]["User"] = context.data.get( "deadlineUser", getpass.getuser()) # Priority is now not handled at all - render_job["Props"]["Pri"] = instance.data.get("priority") + + if self.deadline_priority: + render_job["Props"]["Pri"] = self.deadline_priority + else: + render_job["Props"]["Pri"] = instance.data.get("priority") render_job["Props"]["Env"] = { "FTRACK_API_USER": os.environ.get("FTRACK_API_USER"), @@ -1033,8 +1038,8 @@ class ProcessSubmittedJobOnFarm(pyblish.api.InstancePlugin): anatomy_filled = anatomy.format(template_data) - if "folder" in anatomy.templates["publish"]: - publish_folder = anatomy_filled["publish"]["folder"] + if "folder" in anatomy.templates["render"]: + publish_folder = anatomy_filled["render"]["folder"] else: # solve deprecated situation when `folder` key is not underneath # `publish` anatomy @@ -1044,7 +1049,7 @@ class ProcessSubmittedJobOnFarm(pyblish.api.InstancePlugin): " key underneath `publish` (in global of for project `{}`)." ).format(project_name)) - file_path = anatomy_filled["publish"]["path"] + file_path = anatomy_filled["render"]["path"] # Directory publish_folder = os.path.dirname(file_path) diff --git a/pype/plugins/maya/publish/collect_render.py b/pype/plugins/maya/publish/collect_render.py index 2848a55152..3dde3b1592 100644 --- a/pype/plugins/maya/publish/collect_render.py +++ b/pype/plugins/maya/publish/collect_render.py @@ -254,6 +254,10 @@ class CollectMayaRender(pyblish.api.ContextPlugin): if self.sync_workfile_version: data["version"] = context.data["version"] + for instance in context: + if instance.data['family'] == "workfile": + instance.data["version"] = context.data["version"] + # Apply each user defined attribute as data for attr in cmds.listAttr(layer, userDefined=True) or list(): try: diff --git a/pype/plugins/photoshop/load/load_image.py b/pype/plugins/photoshop/load/load_image.py index 301e60fbb1..44cc96c96f 100644 --- a/pype/plugins/photoshop/load/load_image.py +++ b/pype/plugins/photoshop/load/load_image.py @@ -11,7 +11,7 @@ class ImageLoader(api.Loader): Stores the imported asset in a container named after the asset. """ - families = ["image"] + families = ["image", "render"] representations = ["*"] def load(self, context, name=None, namespace=None, data=None):