Skip to content

Commit

Permalink
Merge pull request #32 from BigRoy/bugfix/fix_usd_publish_asset_contr…
Browse files Browse the repository at this point in the history
…ibution

Fix publishing USD from maya with asset/shot contributions enabled
  • Loading branch information
BigRoy authored Jul 24, 2024
2 parents 0037976 + 2a4257a commit aabee93
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class CollectUserDefinedAttributes(plugin.MayaInstancePlugin):
def process(self, instance):

# Collect user defined attributes.
if not instance.data["creator_attributes"].get(
if not instance.data.get("creator_attributes", {}).get(
"includeUserDefinedAttributes"
):
return
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,15 @@ def get_invalid(cls, instance):

def process(self, instance):
# Allow renderlayer, rendersetup and workfile to be empty
skip_families = {"workfile", "renderlayer", "rendersetup"}
if instance.data.get("productType") in skip_families:
skip_families = {"workfile",
"renderlayer",
"rendersetup",
"mayaUsdLayer",
"usdLayer",
"usdAsset"}
families = {instance.data.get("family")}
families.update(instance.data.get("families", []))
if families.intersection(skip_families):
return

invalid = self.get_invalid(instance)
Expand Down

0 comments on commit aabee93

Please sign in to comment.