mirror of
https://github.com/ynput/ayon-core.git
synced 2026-01-01 16:34:53 +01:00
nuke: collect workfile adding KnownPublishErrorl when untitled
This commit is contained in:
parent
9fbbdad0fd
commit
dd2becdb79
1 changed files with 7 additions and 0 deletions
|
|
@ -8,6 +8,7 @@ from openpype.hosts.nuke.api.lib import (
|
|||
add_publish_knob,
|
||||
get_avalon_knob_data
|
||||
)
|
||||
from openpype.pipeline import KnownPublishError
|
||||
|
||||
|
||||
class CollectWorkfile(pyblish.api.ContextPlugin):
|
||||
|
|
@ -22,6 +23,12 @@ class CollectWorkfile(pyblish.api.ContextPlugin):
|
|||
|
||||
current_file = os.path.normpath(nuke.root().name())
|
||||
|
||||
if current_file.lower() == "root":
|
||||
raise KnownPublishError(
|
||||
"Workfile is not correct file name. \n"
|
||||
"Use workfile tool to manage the name correctly."
|
||||
)
|
||||
|
||||
knob_data = get_avalon_knob_data(root)
|
||||
|
||||
add_publish_knob(root)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue