mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-25 13:24:54 +01:00
Textures publishing - tweaked validator
Look for resources (secondary workfiles) only for main workfile.
This commit is contained in:
parent
abda7f9afa
commit
c2ffeb8953
1 changed files with 9 additions and 1 deletions
|
|
@ -14,8 +14,16 @@ class ValidateTextureBatchWorkfiles(pyblish.api.InstancePlugin):
|
|||
families = ["workfile"]
|
||||
optional = True
|
||||
|
||||
# from presets
|
||||
main_workfile_extensions = ['mra']
|
||||
|
||||
def process(self, instance):
|
||||
if instance.data["family"] == "workfile":
|
||||
msg = "No resources for workfile {}".\
|
||||
ext = instance.data["representations"][0]["ext"]
|
||||
if ext not in self.main_workfile_extensions:
|
||||
self.log.warning("Only secondary workfile present!")
|
||||
return
|
||||
|
||||
msg = "No secondary workfiles present for workfile {}".\
|
||||
format(instance.data["name"])
|
||||
assert instance.data.get("resources"), msg
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue