From a7d5c63228c2e3b56a16fa416653953f4e367237 Mon Sep 17 00:00:00 2001 From: Ondrej Samohel Date: Fri, 9 Jul 2021 12:50:16 +0200 Subject: [PATCH 1/2] =?UTF-8?q?=F0=9F=90=9E:=20fix=20yeti=20settings=20pat?= =?UTF-8?q?h?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- openpype/hosts/maya/plugins/publish/extract_yeti_rig.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/openpype/hosts/maya/plugins/publish/extract_yeti_rig.py b/openpype/hosts/maya/plugins/publish/extract_yeti_rig.py index b9bed47fa5..eef3c4e9af 100644 --- a/openpype/hosts/maya/plugins/publish/extract_yeti_rig.py +++ b/openpype/hosts/maya/plugins/publish/extract_yeti_rig.py @@ -192,12 +192,12 @@ class ExtractYetiRig(openpype.api.Extractor): 'stagingDir': dirname } ) - self.log.info("settings file: {}".format(settings)) + self.log.info("settings file: {}".format(settings_path)) instance.data["representations"].append( { 'name': 'rigsettings', 'ext': 'rigsettings', - 'files': os.path.basename(settings), + 'files': os.path.basename(settings_path), 'stagingDir': dirname } ) From 6e0a51fa7c39a491668bd4e04195ef5a7d7f8154 Mon Sep 17 00:00:00 2001 From: Ondrej Samohel Date: Mon, 12 Jul 2021 12:28:05 +0200 Subject: [PATCH 2/2] remove unnecessary if --- openpype/hosts/maya/plugins/publish/extract_yeti_rig.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/openpype/hosts/maya/plugins/publish/extract_yeti_rig.py b/openpype/hosts/maya/plugins/publish/extract_yeti_rig.py index eef3c4e9af..56d5dfe901 100644 --- a/openpype/hosts/maya/plugins/publish/extract_yeti_rig.py +++ b/openpype/hosts/maya/plugins/publish/extract_yeti_rig.py @@ -133,10 +133,10 @@ class ExtractYetiRig(openpype.api.Extractor): image_search_path = resources_dir = instance.data["resourcesDir"] settings = instance.data.get("rigsettings", None) - if settings: - settings["imageSearchPath"] = image_search_path - with open(settings_path, "w") as fp: - json.dump(settings, fp, ensure_ascii=False) + assert settings, "Yeti rig settings were not collected." + settings["imageSearchPath"] = image_search_path + with open(settings_path, "w") as fp: + json.dump(settings, fp, ensure_ascii=False) # add textures to transfers if 'transfers' not in instance.data: