mirror of
https://github.com/ynput/ayon-core.git
synced 2026-01-02 00:44:52 +01:00
layout publish more than one container issue
This commit is contained in:
parent
d5b1f58fd2
commit
103fd66282
1 changed files with 10 additions and 8 deletions
|
|
@ -39,15 +39,17 @@ class ExtractLayout(publish.Extractor):
|
|||
assert len(container_list) == 1, \
|
||||
"Please create instance with loaded asset"
|
||||
containers = cmds.sets(project_container, query=True)
|
||||
load_asset = asset.split(':')[0]
|
||||
# list the children of the containers
|
||||
ass_transform = cmds.listRelatives(containers, allParents=True)
|
||||
ass = cmds.listRelatives(asset, children=True, type="transform")
|
||||
# compare the group of the asset with
|
||||
# the children list of the container
|
||||
# to find the content which is not loaded from the loader
|
||||
for a in ass:
|
||||
if a not in ass_transform:
|
||||
assert containers == [], \
|
||||
"no container found in {}".format(a)
|
||||
for con in containers:
|
||||
ass_transform = cmds.listRelatives(con, allParents=True)[0]
|
||||
if load_asset not in ass_transform:
|
||||
assert containers == [], \
|
||||
"No container found for {}".format(asset)
|
||||
if "_CON" not in con:
|
||||
assert containers == [], \
|
||||
"Container missing for {}".format(asset)
|
||||
container = con
|
||||
|
||||
representation_id = cmds.getAttr(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue