From 0c0b52d850341681dfde08acc94d36fc660f1617 Mon Sep 17 00:00:00 2001 From: Toke Stuart Jepsen Date: Thu, 5 Oct 2023 11:43:28 +0100 Subject: [PATCH 01/15] Dont update node name on update --- openpype/hosts/nuke/plugins/load/load_image.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/openpype/hosts/nuke/plugins/load/load_image.py b/openpype/hosts/nuke/plugins/load/load_image.py index 0dd3a940db..6bffb97e6f 100644 --- a/openpype/hosts/nuke/plugins/load/load_image.py +++ b/openpype/hosts/nuke/plugins/load/load_image.py @@ -204,8 +204,6 @@ class LoadImage(load.LoaderPlugin): last = first = int(frame_number) # Set the global in to the start frame of the sequence - read_name = self._get_node_name(representation) - node["name"].setValue(read_name) node["file"].setValue(file) node["origfirst"].setValue(first) node["first"].setValue(first) From 519db56b8769a71f18083a1cb972c2e9ae0f567c Mon Sep 17 00:00:00 2001 From: Mustafa-Zarkash Date: Wed, 11 Oct 2023 09:38:48 +0300 Subject: [PATCH 02/15] re-arrange settings files --- .../{publish_plugins.py => create.py} | 85 +------------------ server_addon/houdini/server/settings/main.py | 64 +++----------- .../houdini/server/settings/publish.py | 84 ++++++++++++++++++ .../houdini/server/settings/shelves.py | 43 ++++++++++ server_addon/houdini/server/version.py | 2 +- 5 files changed, 141 insertions(+), 137 deletions(-) rename server_addon/houdini/server/settings/{publish_plugins.py => create.py} (61%) create mode 100644 server_addon/houdini/server/settings/publish.py create mode 100644 server_addon/houdini/server/settings/shelves.py diff --git a/server_addon/houdini/server/settings/publish_plugins.py b/server_addon/houdini/server/settings/create.py similarity index 61% rename from server_addon/houdini/server/settings/publish_plugins.py rename to server_addon/houdini/server/settings/create.py index 58240b0205..a1f8d24c30 100644 --- a/server_addon/houdini/server/settings/publish_plugins.py +++ b/server_addon/houdini/server/settings/create.py @@ -1,5 +1,4 @@ from pydantic import Field - from ayon_server.settings import BaseSettingsModel @@ -37,7 +36,7 @@ class CreateStaticMeshModel(BaseSettingsModel): class CreatePluginsModel(BaseSettingsModel): CreateArnoldAss: CreateArnoldAssModel = Field( default_factory=CreateArnoldAssModel, - title="Create Alembic Camera") + title="Create Arnold Ass") # "-" is not compatible in the new model CreateStaticMesh: CreateStaticMeshModel = Field( default_factory=CreateStaticMeshModel, @@ -135,85 +134,3 @@ DEFAULT_HOUDINI_CREATE_SETTINGS = { "default_variants": ["Main"] }, } - - -# Publish Plugins -class ValidateWorkfilePathsModel(BaseSettingsModel): - enabled: bool = Field(title="Enabled") - optional: bool = Field(title="Optional") - node_types: list[str] = Field( - default_factory=list, - title="Node Types" - ) - prohibited_vars: list[str] = Field( - default_factory=list, - title="Prohibited Variables" - ) - - -class BasicValidateModel(BaseSettingsModel): - enabled: bool = Field(title="Enabled") - optional: bool = Field(title="Optional") - active: bool = Field(title="Active") - - -class PublishPluginsModel(BaseSettingsModel): - ValidateWorkfilePaths: ValidateWorkfilePathsModel = Field( - default_factory=ValidateWorkfilePathsModel, - title="Validate workfile paths settings.") - ValidateReviewColorspace: BasicValidateModel = Field( - default_factory=BasicValidateModel, - title="Validate Review Colorspace.") - ValidateContainers: BasicValidateModel = Field( - default_factory=BasicValidateModel, - title="Validate Latest Containers.") - ValidateSubsetName: BasicValidateModel = Field( - default_factory=BasicValidateModel, - title="Validate Subset Name.") - ValidateMeshIsStatic: BasicValidateModel = Field( - default_factory=BasicValidateModel, - title="Validate Mesh is Static.") - ValidateUnrealStaticMeshName: BasicValidateModel = Field( - default_factory=BasicValidateModel, - title="Validate Unreal Static Mesh Name.") - - -DEFAULT_HOUDINI_PUBLISH_SETTINGS = { - "ValidateWorkfilePaths": { - "enabled": True, - "optional": True, - "node_types": [ - "file", - "alembic" - ], - "prohibited_vars": [ - "$HIP", - "$JOB" - ] - }, - "ValidateReviewColorspace": { - "enabled": True, - "optional": True, - "active": True - }, - "ValidateContainers": { - "enabled": True, - "optional": True, - "active": True - }, - "ValidateSubsetName": { - "enabled": True, - "optional": True, - "active": True - }, - "ValidateMeshIsStatic": { - "enabled": True, - "optional": True, - "active": True - }, - "ValidateUnrealStaticMeshName": { - "enabled": False, - "optional": True, - "active": True - } -} diff --git a/server_addon/houdini/server/settings/main.py b/server_addon/houdini/server/settings/main.py index 0c2e160c87..9cfec54f22 100644 --- a/server_addon/houdini/server/settings/main.py +++ b/server_addon/houdini/server/settings/main.py @@ -1,57 +1,19 @@ from pydantic import Field -from ayon_server.settings import ( - BaseSettingsModel, - MultiplatformPathModel, - MultiplatformPathListModel, -) +from ayon_server.settings import BaseSettingsModel from .general import ( GeneralSettingsModel, DEFAULT_GENERAL_SETTINGS ) from .imageio import HoudiniImageIOModel -from .publish_plugins import ( - PublishPluginsModel, +from .shelves import ShelvesModel +from .create import ( CreatePluginsModel, - DEFAULT_HOUDINI_PUBLISH_SETTINGS, DEFAULT_HOUDINI_CREATE_SETTINGS ) - - -class ShelfToolsModel(BaseSettingsModel): - name: str = Field(title="Name") - help: str = Field(title="Help text") - script: MultiplatformPathModel = Field( - default_factory=MultiplatformPathModel, - title="Script Path " - ) - icon: MultiplatformPathModel = Field( - default_factory=MultiplatformPathModel, - title="Icon Path " - ) - - -class ShelfDefinitionModel(BaseSettingsModel): - _layout = "expanded" - shelf_name: str = Field(title="Shelf name") - tools_list: list[ShelfToolsModel] = Field( - default_factory=list, - title="Shelf Tools" - ) - - -class ShelvesModel(BaseSettingsModel): - _layout = "expanded" - shelf_set_name: str = Field(title="Shelfs set name") - - shelf_set_source_path: MultiplatformPathListModel = Field( - default_factory=MultiplatformPathListModel, - title="Shelf Set Path (optional)" - ) - - shelf_definition: list[ShelfDefinitionModel] = Field( - default_factory=list, - title="Shelf Definitions" - ) +from .publish import ( + PublishPluginsModel, + DEFAULT_HOUDINI_PUBLISH_SETTINGS, +) class HoudiniSettings(BaseSettingsModel): @@ -65,18 +27,16 @@ class HoudiniSettings(BaseSettingsModel): ) shelves: list[ShelvesModel] = Field( default_factory=list, - title="Houdini Scripts Shelves", + title="Shelves Manager", ) - - publish: PublishPluginsModel = Field( - default_factory=PublishPluginsModel, - title="Publish Plugins", - ) - create: CreatePluginsModel = Field( default_factory=CreatePluginsModel, title="Creator Plugins", ) + publish: PublishPluginsModel = Field( + default_factory=PublishPluginsModel, + title="Publish Plugins", + ) DEFAULT_VALUES = { diff --git a/server_addon/houdini/server/settings/publish.py b/server_addon/houdini/server/settings/publish.py new file mode 100644 index 0000000000..7612c446bf --- /dev/null +++ b/server_addon/houdini/server/settings/publish.py @@ -0,0 +1,84 @@ +from pydantic import Field +from ayon_server.settings import BaseSettingsModel + + +# Publish Plugins +class ValidateWorkfilePathsModel(BaseSettingsModel): + enabled: bool = Field(title="Enabled") + optional: bool = Field(title="Optional") + node_types: list[str] = Field( + default_factory=list, + title="Node Types" + ) + prohibited_vars: list[str] = Field( + default_factory=list, + title="Prohibited Variables" + ) + + +class BasicValidateModel(BaseSettingsModel): + enabled: bool = Field(title="Enabled") + optional: bool = Field(title="Optional") + active: bool = Field(title="Active") + + +class PublishPluginsModel(BaseSettingsModel): + ValidateWorkfilePaths: ValidateWorkfilePathsModel = Field( + default_factory=ValidateWorkfilePathsModel, + title="Validate workfile paths settings.") + ValidateReviewColorspace: BasicValidateModel = Field( + default_factory=BasicValidateModel, + title="Validate Review Colorspace.") + ValidateContainers: BasicValidateModel = Field( + default_factory=BasicValidateModel, + title="Validate Latest Containers.") + ValidateSubsetName: BasicValidateModel = Field( + default_factory=BasicValidateModel, + title="Validate Subset Name.") + ValidateMeshIsStatic: BasicValidateModel = Field( + default_factory=BasicValidateModel, + title="Validate Mesh is Static.") + ValidateUnrealStaticMeshName: BasicValidateModel = Field( + default_factory=BasicValidateModel, + title="Validate Unreal Static Mesh Name.") + + +DEFAULT_HOUDINI_PUBLISH_SETTINGS = { + "ValidateWorkfilePaths": { + "enabled": True, + "optional": True, + "node_types": [ + "file", + "alembic" + ], + "prohibited_vars": [ + "$HIP", + "$JOB" + ] + }, + "ValidateReviewColorspace": { + "enabled": True, + "optional": True, + "active": True + }, + "ValidateContainers": { + "enabled": True, + "optional": True, + "active": True + }, + "ValidateSubsetName": { + "enabled": True, + "optional": True, + "active": True + }, + "ValidateMeshIsStatic": { + "enabled": True, + "optional": True, + "active": True + }, + "ValidateUnrealStaticMeshName": { + "enabled": False, + "optional": True, + "active": True + } +} diff --git a/server_addon/houdini/server/settings/shelves.py b/server_addon/houdini/server/settings/shelves.py new file mode 100644 index 0000000000..2319357f59 --- /dev/null +++ b/server_addon/houdini/server/settings/shelves.py @@ -0,0 +1,43 @@ +from pydantic import Field +from ayon_server.settings import ( + BaseSettingsModel, + MultiplatformPathModel, + MultiplatformPathListModel, +) + + +class ShelfToolsModel(BaseSettingsModel): + name: str = Field(title="Name") + help: str = Field(title="Help text") + script: MultiplatformPathModel = Field( + default_factory=MultiplatformPathModel, + title="Script Path " + ) + icon: MultiplatformPathModel = Field( + default_factory=MultiplatformPathModel, + title="Icon Path " + ) + + +class ShelfDefinitionModel(BaseSettingsModel): + _layout = "expanded" + shelf_name: str = Field(title="Shelf name") + tools_list: list[ShelfToolsModel] = Field( + default_factory=list, + title="Shelf Tools" + ) + + +class ShelvesModel(BaseSettingsModel): + _layout = "expanded" + shelf_set_name: str = Field(title="Shelfs set name") + + shelf_set_source_path: MultiplatformPathListModel = Field( + default_factory=MultiplatformPathListModel, + title="Shelf Set Path (optional)" + ) + + shelf_definition: list[ShelfDefinitionModel] = Field( + default_factory=list, + title="Shelf Definitions" + ) diff --git a/server_addon/houdini/server/version.py b/server_addon/houdini/server/version.py index bbab0242f6..1276d0254f 100644 --- a/server_addon/houdini/server/version.py +++ b/server_addon/houdini/server/version.py @@ -1 +1 @@ -__version__ = "0.1.4" +__version__ = "0.1.5" From 45b61c21711b92c5a59e73b1125c2da2696d62de Mon Sep 17 00:00:00 2001 From: Mustafa-Zarkash Date: Wed, 11 Oct 2023 23:12:42 +0300 Subject: [PATCH 03/15] update create and publish plugins --- .../houdini/server/settings/create.py | 146 +++++++++++------- .../houdini/server/settings/publish.py | 68 ++++---- 2 files changed, 124 insertions(+), 90 deletions(-) diff --git a/server_addon/houdini/server/settings/create.py b/server_addon/houdini/server/settings/create.py index a1f8d24c30..81b871e83f 100644 --- a/server_addon/houdini/server/settings/create.py +++ b/server_addon/houdini/server/settings/create.py @@ -34,52 +34,110 @@ class CreateStaticMeshModel(BaseSettingsModel): class CreatePluginsModel(BaseSettingsModel): - CreateArnoldAss: CreateArnoldAssModel = Field( - default_factory=CreateArnoldAssModel, - title="Create Arnold Ass") - # "-" is not compatible in the new model - CreateStaticMesh: CreateStaticMeshModel = Field( - default_factory=CreateStaticMeshModel, - title="Create Static Mesh" - ) CreateAlembicCamera: CreatorModel = Field( default_factory=CreatorModel, title="Create Alembic Camera") + CreateArnoldAss: CreateArnoldAssModel = Field( + default_factory=CreateArnoldAssModel, + title="Create Arnold Ass") + CreateArnoldRop: CreatorModel = Field( + default_factory=CreatorModel, + title="Create Arnold ROP") CreateCompositeSequence: CreatorModel = Field( default_factory=CreatorModel, - title="Create Composite Sequence") + title="Create Composite (Image Sequence)") + CreateHDA: CreatorModel = Field( + default_factory=CreatorModel, + title="Create Houdini Digital Asset") + CreateKarmaROP: CreatorModel = Field( + default_factory=CreatorModel, + title="Create Karma ROP") + CreateMantraROP: CreatorModel = Field( + default_factory=CreatorModel, + title="Create Mantra ROP") CreatePointCache: CreatorModel = Field( default_factory=CreatorModel, - title="Create Point Cache") + title="Create PointCache (Abc)") + CreateBGEO: CreatorModel = Field( + default_factory=CreatorModel, + title="Create PointCache (Bgeo)") + CreateRedshiftProxy: CreatorModel = Field( + default_factory=CreatorModel, + title="Create Redshift Proxy") CreateRedshiftROP: CreatorModel = Field( default_factory=CreatorModel, - title="Create RedshiftROP") - CreateRemotePublish: CreatorModel = Field( + title="Create Redshift ROP") + CreateReview: CreatorModel = Field( default_factory=CreatorModel, - title="Create Remote Publish") + title="Create Review") + # "-" is not compatible in the new model + CreateStaticMesh: CreateStaticMeshModel = Field( + default_factory=CreateStaticMeshModel, + title="Create Static Mesh") + CreateUSD: CreatorModel = Field( + default_factory=CreatorModel, + title="Create USD (experimental)") + CreateUSDRender: CreatorModel = Field( + default_factory=CreatorModel, + title="Create USD render (experimental)") CreateVDBCache: CreatorModel = Field( default_factory=CreatorModel, title="Create VDB Cache") - CreateUSD: CreatorModel = Field( + CreateVrayROP: CreatorModel = Field( default_factory=CreatorModel, - title="Create USD") - CreateUSDModel: CreatorModel = Field( - default_factory=CreatorModel, - title="Create USD model") - USDCreateShadingWorkspace: CreatorModel = Field( - default_factory=CreatorModel, - title="Create USD shading workspace") - CreateUSDRender: CreatorModel = Field( - default_factory=CreatorModel, - title="Create USD render") + title="Create VRay ROP") DEFAULT_HOUDINI_CREATE_SETTINGS = { + "CreateAlembicCamera": { + "enabled": True, + "default_variants": ["Main"] + }, "CreateArnoldAss": { "enabled": True, "default_variants": ["Main"], "ext": ".ass" }, + "CreateArnoldRop": { + "enabled": True, + "default_variants": ["Main"] + }, + "CreateCompositeSequence": { + "enabled": True, + "default_variants": ["Main"] + }, + "CreateHDA": { + "enabled": True, + "default_variants": ["Main"] + }, + "CreateKarmaROP": { + "enabled": True, + "default_variants": ["Main"] + }, + "CreateMantraROP": { + "enabled": True, + "default_variants": ["Main"] + }, + "CreatePointCache": { + "enabled": True, + "default_variants": ["Main"] + }, + "CreateBGEO": { + "enabled": True, + "default_variants": ["Main"] + }, + "CreateRedshiftProxy": { + "enabled": True, + "default_variants": ["Main"] + }, + "CreateRedshiftROP": { + "enabled": True, + "default_variants": ["Main"] + }, + "CreateReview": { + "enabled": True, + "default_variants": ["Main"] + }, "CreateStaticMesh": { "enabled": True, "default_variants": [ @@ -93,44 +151,20 @@ DEFAULT_HOUDINI_CREATE_SETTINGS = { "UCX" ] }, - "CreateAlembicCamera": { - "enabled": True, - "default_variants": ["Main"] - }, - "CreateCompositeSequence": { - "enabled": True, - "default_variants": ["Main"] - }, - "CreatePointCache": { - "enabled": True, - "default_variants": ["Main"] - }, - "CreateRedshiftROP": { - "enabled": True, - "default_variants": ["Main"] - }, - "CreateRemotePublish": { - "enabled": True, - "default_variants": ["Main"] - }, - "CreateVDBCache": { - "enabled": True, - "default_variants": ["Main"] - }, "CreateUSD": { "enabled": False, "default_variants": ["Main"] }, - "CreateUSDModel": { - "enabled": False, - "default_variants": ["Main"] - }, - "USDCreateShadingWorkspace": { - "enabled": False, - "default_variants": ["Main"] - }, "CreateUSDRender": { "enabled": False, "default_variants": ["Main"] }, + "CreateVDBCache": { + "enabled": True, + "default_variants": ["Main"] + }, + "CreateVrayROP": { + "enabled": True, + "default_variants": ["Main"] + }, } diff --git a/server_addon/houdini/server/settings/publish.py b/server_addon/houdini/server/settings/publish.py index 7612c446bf..5a1ee1fa07 100644 --- a/server_addon/houdini/server/settings/publish.py +++ b/server_addon/houdini/server/settings/publish.py @@ -23,27 +23,52 @@ class BasicValidateModel(BaseSettingsModel): class PublishPluginsModel(BaseSettingsModel): - ValidateWorkfilePaths: ValidateWorkfilePathsModel = Field( - default_factory=ValidateWorkfilePathsModel, - title="Validate workfile paths settings.") - ValidateReviewColorspace: BasicValidateModel = Field( - default_factory=BasicValidateModel, - title="Validate Review Colorspace.") ValidateContainers: BasicValidateModel = Field( default_factory=BasicValidateModel, title="Validate Latest Containers.") - ValidateSubsetName: BasicValidateModel = Field( - default_factory=BasicValidateModel, - title="Validate Subset Name.") ValidateMeshIsStatic: BasicValidateModel = Field( default_factory=BasicValidateModel, title="Validate Mesh is Static.") + ValidateReviewColorspace: BasicValidateModel = Field( + default_factory=BasicValidateModel, + title="Validate Review Colorspace.") + ValidateSubsetName: BasicValidateModel = Field( + default_factory=BasicValidateModel, + title="Validate Subset Name.") ValidateUnrealStaticMeshName: BasicValidateModel = Field( default_factory=BasicValidateModel, title="Validate Unreal Static Mesh Name.") + ValidateWorkfilePaths: ValidateWorkfilePathsModel = Field( + default_factory=ValidateWorkfilePathsModel, + title="Validate workfile paths settings.") DEFAULT_HOUDINI_PUBLISH_SETTINGS = { + "ValidateContainers": { + "enabled": True, + "optional": True, + "active": True + }, + "ValidateMeshIsStatic": { + "enabled": True, + "optional": True, + "active": True + }, + "ValidateReviewColorspace": { + "enabled": True, + "optional": True, + "active": True + }, + "ValidateSubsetName": { + "enabled": True, + "optional": True, + "active": True + }, + "ValidateUnrealStaticMeshName": { + "enabled": False, + "optional": True, + "active": True + }, "ValidateWorkfilePaths": { "enabled": True, "optional": True, @@ -55,30 +80,5 @@ DEFAULT_HOUDINI_PUBLISH_SETTINGS = { "$HIP", "$JOB" ] - }, - "ValidateReviewColorspace": { - "enabled": True, - "optional": True, - "active": True - }, - "ValidateContainers": { - "enabled": True, - "optional": True, - "active": True - }, - "ValidateSubsetName": { - "enabled": True, - "optional": True, - "active": True - }, - "ValidateMeshIsStatic": { - "enabled": True, - "optional": True, - "active": True - }, - "ValidateUnrealStaticMeshName": { - "enabled": False, - "optional": True, - "active": True } } From 848953f026493244a0de98bbf6df6f6d0f421e73 Mon Sep 17 00:00:00 2001 From: Mustafa-Zarkash Date: Thu, 12 Oct 2023 18:01:12 +0300 Subject: [PATCH 04/15] add sections --- server_addon/houdini/server/settings/publish.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/server_addon/houdini/server/settings/publish.py b/server_addon/houdini/server/settings/publish.py index 5a1ee1fa07..ab1b71c6bb 100644 --- a/server_addon/houdini/server/settings/publish.py +++ b/server_addon/houdini/server/settings/publish.py @@ -25,7 +25,8 @@ class BasicValidateModel(BaseSettingsModel): class PublishPluginsModel(BaseSettingsModel): ValidateContainers: BasicValidateModel = Field( default_factory=BasicValidateModel, - title="Validate Latest Containers.") + title="Validate Latest Containers.", + section="Validators") ValidateMeshIsStatic: BasicValidateModel = Field( default_factory=BasicValidateModel, title="Validate Mesh is Static.") From 05dc8f557da1edddf3d53991bb0d4f766a6dc9bd Mon Sep 17 00:00:00 2001 From: Mustafa-Zarkash Date: Thu, 12 Oct 2023 18:02:13 +0300 Subject: [PATCH 05/15] Align Openpype with Ayon --- .../defaults/project_settings/houdini.json | 160 +++++++++++------- .../schemas/schema_houdini_create.json | 92 ++++++---- .../schemas/schema_houdini_publish.json | 56 +++--- 3 files changed, 187 insertions(+), 121 deletions(-) diff --git a/openpype/settings/defaults/project_settings/houdini.json b/openpype/settings/defaults/project_settings/houdini.json index 4f57ee52c6..f28beac65d 100644 --- a/openpype/settings/defaults/project_settings/houdini.json +++ b/openpype/settings/defaults/project_settings/houdini.json @@ -24,6 +24,12 @@ }, "shelves": [], "create": { + "CreateAlembicCamera": { + "enabled": true, + "default_variants": [ + "Main" + ] + }, "CreateArnoldAss": { "enabled": true, "default_variants": [ @@ -31,6 +37,66 @@ ], "ext": ".ass" }, + "CreateArnoldRop": { + "enabled": true, + "default_variants": [ + "Main" + ] + }, + "CreateCompositeSequence": { + "enabled": true, + "default_variants": [ + "Main" + ] + }, + "CreateHDA": { + "enabled": true, + "default_variants": [ + "Main" + ] + }, + "CreateKarmaROP": { + "enabled": true, + "default_variants": [ + "Main" + ] + }, + "CreateMantraROP": { + "enabled": true, + "default_variants": [ + "Main" + ] + }, + "CreatePointCache": { + "enabled": true, + "default_variants": [ + "Main" + ] + }, + "CreateBGEO": { + "enabled": true, + "default_variants": [ + "Main" + ] + }, + "CreateRedshiftProxy": { + "enabled": true, + "default_variants": [ + "Main" + ] + }, + "CreateRedshiftROP": { + "enabled": true, + "default_variants": [ + "Main" + ] + }, + "CreateReview": { + "enabled": true, + "default_variants": [ + "Main" + ] + }, "CreateStaticMesh": { "enabled": true, "default_variants": [ @@ -44,31 +110,13 @@ "UCX" ] }, - "CreateAlembicCamera": { + "CreateUSD": { "enabled": true, "default_variants": [ "Main" ] }, - "CreateCompositeSequence": { - "enabled": true, - "default_variants": [ - "Main" - ] - }, - "CreatePointCache": { - "enabled": true, - "default_variants": [ - "Main" - ] - }, - "CreateRedshiftROP": { - "enabled": true, - "default_variants": [ - "Main" - ] - }, - "CreateRemotePublish": { + "CreateUSDRender": { "enabled": true, "default_variants": [ "Main" @@ -80,32 +128,39 @@ "Main" ] }, - "CreateUSD": { - "enabled": false, - "default_variants": [ - "Main" - ] - }, - "CreateUSDModel": { - "enabled": false, - "default_variants": [ - "Main" - ] - }, - "USDCreateShadingWorkspace": { - "enabled": false, - "default_variants": [ - "Main" - ] - }, - "CreateUSDRender": { - "enabled": false, + "CreateVrayROP": { + "enabled": true, "default_variants": [ "Main" ] } }, "publish": { + "ValidateContainers": { + "enabled": true, + "optional": true, + "active": true + }, + "ValidateMeshIsStatic": { + "enabled": true, + "optional": true, + "active": true + }, + "ValidateReviewColorspace": { + "enabled": true, + "optional": true, + "active": true + }, + "ValidateSubsetName": { + "enabled": true, + "optional": true, + "active": true + }, + "ValidateUnrealStaticMeshName": { + "enabled": false, + "optional": true, + "active": true + }, "ValidateWorkfilePaths": { "enabled": true, "optional": true, @@ -117,31 +172,6 @@ "$HIP", "$JOB" ] - }, - "ValidateReviewColorspace": { - "enabled": true, - "optional": true, - "active": true - }, - "ValidateContainers": { - "enabled": true, - "optional": true, - "active": true - }, - "ValidateSubsetName": { - "enabled": true, - "optional": true, - "active": true - }, - "ValidateMeshIsStatic": { - "enabled": true, - "optional": true, - "active": true - }, - "ValidateUnrealStaticMeshName": { - "enabled": false, - "optional": true, - "active": true } } } diff --git a/openpype/settings/entities/schemas/projects_schema/schemas/schema_houdini_create.json b/openpype/settings/entities/schemas/projects_schema/schemas/schema_houdini_create.json index cd8c260124..f37738c4ec 100644 --- a/openpype/settings/entities/schemas/projects_schema/schemas/schema_houdini_create.json +++ b/openpype/settings/entities/schemas/projects_schema/schemas/schema_houdini_create.json @@ -4,6 +4,16 @@ "key": "create", "label": "Creator plugins", "children": [ + { + "type": "schema_template", + "name": "template_create_plugin", + "template_data": [ + { + "key": "CreateAlembicCamera", + "label": "Create Alembic Camera" + } + ] + }, { "type": "dict", "collapsible": true, @@ -39,6 +49,52 @@ ] }, + { + "type": "schema_template", + "name": "template_create_plugin", + "template_data": [ + { + "key": "CreateArnoldRop", + "label": "Create Arnold ROP" + }, + { + "key": "CreateCompositeSequence", + "label": "Create Composite (Image Sequence)" + }, + { + "key": "CreateHDA", + "label": "Create Houdini Digital Asset" + }, + { + "key": "CreateKarmaROP", + "label": "Create Karma ROP" + }, + { + "key": "CreateMantraROP", + "label": "Create Mantra ROP" + }, + { + "key": "CreatePointCache", + "label": "Create PointCache (Abc)" + }, + { + "key": "CreateBGEO", + "label": "Create PointCache (Bgeo)" + }, + { + "key": "CreateRedshiftProxy", + "label": "Create Redshift Proxy" + }, + { + "key": "CreateRedshiftROP", + "label": "Create Redshift ROP" + }, + { + "key": "CreateReview", + "label": "Create Review" + } + ] + }, { "type": "dict", "collapsible": true, @@ -75,44 +131,20 @@ "name": "template_create_plugin", "template_data": [ { - "key": "CreateAlembicCamera", - "label": "Create Alembic Camera" + "key": "CreateUSD", + "label": "Create USD (experimental)" }, { - "key": "CreateCompositeSequence", - "label": "Create Composite (Image Sequence)" - }, - { - "key": "CreatePointCache", - "label": "Create Point Cache" - }, - { - "key": "CreateRedshiftROP", - "label": "Create Redshift ROP" - }, - { - "key": "CreateRemotePublish", - "label": "Create Remote Publish" + "key": "CreateUSDRender", + "label": "Create USD render (experimental)" }, { "key": "CreateVDBCache", "label": "Create VDB Cache" }, { - "key": "CreateUSD", - "label": "Create USD" - }, - { - "key": "CreateUSDModel", - "label": "Create USD Model" - }, - { - "key": "USDCreateShadingWorkspace", - "label": "Create USD Shading Workspace" - }, - { - "key": "CreateUSDRender", - "label": "Create USD Render" + "key": "CreateVrayROP", + "label": "Create VRay ROP" } ] } diff --git a/openpype/settings/entities/schemas/projects_schema/schemas/schema_houdini_publish.json b/openpype/settings/entities/schemas/projects_schema/schemas/schema_houdini_publish.json index d5f70b0312..e202e7b615 100644 --- a/openpype/settings/entities/schemas/projects_schema/schemas/schema_houdini_publish.json +++ b/openpype/settings/entities/schemas/projects_schema/schemas/schema_houdini_publish.json @@ -4,6 +4,36 @@ "key": "publish", "label": "Publish plugins", "children": [ + { + "type": "label", + "label": "Validators" + }, + { + "type": "schema_template", + "name": "template_publish_plugin", + "template_data": [ + { + "key": "ValidateContainers", + "label": "Validate Containers" + }, + { + "key": "ValidateMeshIsStatic", + "label": "Validate Mesh is Static" + }, + { + "key": "ValidateReviewColorspace", + "label": "Validate Review Colorspace" + }, + { + "key": "ValidateSubsetName", + "label": "Validate Subset Name" + }, + { + "key": "ValidateUnrealStaticMeshName", + "label": "Validate Unreal Static Mesh Name" + } + ] + }, { "type": "dict", "collapsible": true, @@ -35,32 +65,6 @@ "object_type": "text" } ] - }, - { - "type": "schema_template", - "name": "template_publish_plugin", - "template_data": [ - { - "key": "ValidateReviewColorspace", - "label": "Validate Review Colorspace" - }, - { - "key": "ValidateContainers", - "label": "ValidateContainers" - }, - { - "key": "ValidateSubsetName", - "label": "Validate Subset Name" - }, - { - "key": "ValidateMeshIsStatic", - "label": "Validate Mesh is Static" - }, - { - "key": "ValidateUnrealStaticMeshName", - "label": "Validate Unreal Static Mesh Name" - } - ] } ] } From 873c263587703db10872bbb16536413628cbfdc2 Mon Sep 17 00:00:00 2001 From: Mustafa-Zarkash Date: Thu, 12 Oct 2023 21:15:23 +0300 Subject: [PATCH 06/15] add a TODO in shelves manager --- server_addon/houdini/server/settings/shelves.py | 1 + 1 file changed, 1 insertion(+) diff --git a/server_addon/houdini/server/settings/shelves.py b/server_addon/houdini/server/settings/shelves.py index 2319357f59..c8bda515f9 100644 --- a/server_addon/houdini/server/settings/shelves.py +++ b/server_addon/houdini/server/settings/shelves.py @@ -9,6 +9,7 @@ from ayon_server.settings import ( class ShelfToolsModel(BaseSettingsModel): name: str = Field(title="Name") help: str = Field(title="Help text") + # TODO: The following settings are not compatible with OP script: MultiplatformPathModel = Field( default_factory=MultiplatformPathModel, title="Script Path " From 211d64c3dea458b18ba268a66fa2e292dcf0ed7d Mon Sep 17 00:00:00 2001 From: Mustafa-Zarkash Date: Wed, 18 Oct 2023 11:39:31 +0300 Subject: [PATCH 07/15] align houdini shelves manager in OP and Ayon --- .../schemas/schema_houdini_scriptshelf.json | 6 ++++- .../houdini/server/settings/shelves.py | 25 +++++++------------ 2 files changed, 14 insertions(+), 17 deletions(-) diff --git a/openpype/settings/entities/schemas/projects_schema/schemas/schema_houdini_scriptshelf.json b/openpype/settings/entities/schemas/projects_schema/schemas/schema_houdini_scriptshelf.json index bab9b604b4..35d768843d 100644 --- a/openpype/settings/entities/schemas/projects_schema/schemas/schema_houdini_scriptshelf.json +++ b/openpype/settings/entities/schemas/projects_schema/schemas/schema_houdini_scriptshelf.json @@ -40,6 +40,10 @@ "object_type": { "type": "dict", "children": [ + { + "type": "label", + "label": "Name and Script Path are mandatory." + }, { "type": "text", "key": "label", @@ -68,4 +72,4 @@ } ] } -} \ No newline at end of file +} diff --git a/server_addon/houdini/server/settings/shelves.py b/server_addon/houdini/server/settings/shelves.py index c8bda515f9..ac7922e058 100644 --- a/server_addon/houdini/server/settings/shelves.py +++ b/server_addon/houdini/server/settings/shelves.py @@ -1,23 +1,16 @@ from pydantic import Field from ayon_server.settings import ( BaseSettingsModel, - MultiplatformPathModel, - MultiplatformPathListModel, + MultiplatformPathModel ) class ShelfToolsModel(BaseSettingsModel): - name: str = Field(title="Name") - help: str = Field(title="Help text") - # TODO: The following settings are not compatible with OP - script: MultiplatformPathModel = Field( - default_factory=MultiplatformPathModel, - title="Script Path " - ) - icon: MultiplatformPathModel = Field( - default_factory=MultiplatformPathModel, - title="Icon Path " - ) + """Name and Script Path are mandatory.""" + label: str = Field(title="Name") + script: str = Field(title="Script Path") + icon: str = Field( "", title="Icon Path") + help: str = Field("", title="Help text") class ShelfDefinitionModel(BaseSettingsModel): @@ -31,10 +24,10 @@ class ShelfDefinitionModel(BaseSettingsModel): class ShelvesModel(BaseSettingsModel): _layout = "expanded" - shelf_set_name: str = Field(title="Shelfs set name") + shelf_set_name: str = Field("", title="Shelfs set name") - shelf_set_source_path: MultiplatformPathListModel = Field( - default_factory=MultiplatformPathListModel, + shelf_set_source_path: MultiplatformPathModel = Field( + default_factory=MultiplatformPathModel, title="Shelf Set Path (optional)" ) From 6fb59e3085f7d621dcbde1d9b8ed8ed82081e51b Mon Sep 17 00:00:00 2001 From: Mustafa-Zarkash Date: Wed, 18 Oct 2023 12:36:43 +0300 Subject: [PATCH 08/15] resolve hound --- server_addon/houdini/server/settings/shelves.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server_addon/houdini/server/settings/shelves.py b/server_addon/houdini/server/settings/shelves.py index ac7922e058..8d0512bdeb 100644 --- a/server_addon/houdini/server/settings/shelves.py +++ b/server_addon/houdini/server/settings/shelves.py @@ -9,7 +9,7 @@ class ShelfToolsModel(BaseSettingsModel): """Name and Script Path are mandatory.""" label: str = Field(title="Name") script: str = Field(title="Script Path") - icon: str = Field( "", title="Icon Path") + icon: str = Field("", title="Icon Path") help: str = Field("", title="Help text") From 559750c07ce69e30a0d398a039a88bbe3f3d787c Mon Sep 17 00:00:00 2001 From: MustafaJafar Date: Wed, 18 Oct 2023 17:42:51 +0300 Subject: [PATCH 09/15] bump houdini addon version --- server_addon/houdini/server/version.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server_addon/houdini/server/version.py b/server_addon/houdini/server/version.py index 1276d0254f..0a8da88258 100644 --- a/server_addon/houdini/server/version.py +++ b/server_addon/houdini/server/version.py @@ -1 +1 @@ -__version__ = "0.1.5" +__version__ = "0.1.6" From 84abccce4ea26ce45fb0e86d3a895e20356c833f Mon Sep 17 00:00:00 2001 From: MustafaJafar Date: Thu, 26 Oct 2023 09:49:23 +0300 Subject: [PATCH 10/15] retrieve settings that missed by merge --- .../houdini/server/settings/publish.py | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/server_addon/houdini/server/settings/publish.py b/server_addon/houdini/server/settings/publish.py index ab1b71c6bb..6615e34ca5 100644 --- a/server_addon/houdini/server/settings/publish.py +++ b/server_addon/houdini/server/settings/publish.py @@ -3,6 +3,16 @@ from ayon_server.settings import BaseSettingsModel # Publish Plugins +class CollectRopFrameRangeModel(BaseSettingsModel): + """Collect Frame Range + Disable this if you want the publisher to + ignore start and end handles specified in the + asset data for publish instances + """ + use_asset_handles: bool = Field( + title="Use asset handles") + + class ValidateWorkfilePathsModel(BaseSettingsModel): enabled: bool = Field(title="Enabled") optional: bool = Field(title="Optional") @@ -23,6 +33,11 @@ class BasicValidateModel(BaseSettingsModel): class PublishPluginsModel(BaseSettingsModel): + CollectRopFrameRange: CollectRopFrameRangeModel = Field( + default_factory=CollectRopFrameRangeModel, + title="Collect Rop Frame Range.", + section="Collectors" + ) ValidateContainers: BasicValidateModel = Field( default_factory=BasicValidateModel, title="Validate Latest Containers.", @@ -45,6 +60,9 @@ class PublishPluginsModel(BaseSettingsModel): DEFAULT_HOUDINI_PUBLISH_SETTINGS = { + "CollectRopFrameRange": { + "use_asset_handles": True + }, "ValidateContainers": { "enabled": True, "optional": True, From 64be3b09830f4a793ae9219d071ea044a46e1d2c Mon Sep 17 00:00:00 2001 From: MustafaJafar Date: Thu, 26 Oct 2023 09:49:57 +0300 Subject: [PATCH 11/15] bump minor version --- server_addon/houdini/server/version.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server_addon/houdini/server/version.py b/server_addon/houdini/server/version.py index 0a8da88258..01ef12070d 100644 --- a/server_addon/houdini/server/version.py +++ b/server_addon/houdini/server/version.py @@ -1 +1 @@ -__version__ = "0.1.6" +__version__ = "0.2.6" From 3b1b59916662b528ba7fee1e952511f32a615284 Mon Sep 17 00:00:00 2001 From: Jakub Jezek Date: Thu, 26 Oct 2023 14:18:11 +0200 Subject: [PATCH 12/15] updating create ayon addon script - adding argparse module - adding `output` for targeting to specfic folder (ayon-docker/addons) - adding `dont-clear-output` for avoiding clearing already created folders and versions in addons --- server_addon/create_ayon_addons.py | 64 +++++++++++++++++++++++++----- 1 file changed, 55 insertions(+), 9 deletions(-) diff --git a/server_addon/create_ayon_addons.py b/server_addon/create_ayon_addons.py index 61dbd5c8d9..47711244c3 100644 --- a/server_addon/create_ayon_addons.py +++ b/server_addon/create_ayon_addons.py @@ -3,6 +3,7 @@ import sys import re import json import shutil +import argparse import zipfile import platform import collections @@ -185,8 +186,8 @@ def create_openpype_package( addon_output_dir = output_dir / "openpype" / addon_version private_dir = addon_output_dir / "private" # Make sure dir exists - addon_output_dir.mkdir(parents=True) - private_dir.mkdir(parents=True) + addon_output_dir.mkdir(parents=True, exist_ok=True) + private_dir.mkdir(parents=True, exist_ok=True) # Copy version shutil.copy(str(version_path), str(addon_output_dir)) @@ -268,19 +269,29 @@ def create_addon_package( ) -def main(create_zip=True, keep_source=False): +def main(output_dir=None, skip_zip=True, keep_source=False, clear_output_dir=False): current_dir = Path(os.path.dirname(os.path.abspath(__file__))) root_dir = current_dir.parent - output_dir = current_dir / "packages" + create_zip = not skip_zip + + output_dir = Path(output_dir) if output_dir else current_dir / "packages" + print("Current directory:", current_dir) + print("Root directory:", root_dir) + print("Skip zip:", skip_zip) + print("Clear output dir:", clear_output_dir) + print("Keep source:", keep_source) print("Package creation started...") + print(f"Output directory: {output_dir}") # Make sure package dir is empty - if output_dir.exists(): + if output_dir.exists() and clear_output_dir: shutil.rmtree(str(output_dir)) + # Make sure output dir is created - output_dir.mkdir(parents=True) + output_dir.mkdir(parents=True, exist_ok=True) for addon_dir in current_dir.iterdir(): + print(f"Processing addon: {addon_dir.name}") if not addon_dir.is_dir(): continue @@ -303,6 +314,41 @@ def main(create_zip=True, keep_source=False): if __name__ == "__main__": - create_zip = "--skip-zip" not in sys.argv - keep_sources = "--keep-sources" in sys.argv - main(create_zip, keep_sources) + parser = argparse.ArgumentParser() + parser.add_argument( + "--skip-zip", + dest="skip_zip", + action="store_true", + help=( + "Skip zipping server package and create only" + " server folder structure." + ) + ) + parser.add_argument( + "--keep-sources", + dest="keep_sources", + action="store_true", + help=( + "Keep folder structure when server package is created." + ) + ) + parser.add_argument( + "-o", "--output", + dest="output_dir", + default=None, + help=( + "Directory path where package will be created" + " (Will be purged if already exists!)" + ) + ) + parser.add_argument( + "-c", "--dont-clear-output", + dest="clear_output_dir", + action="store_false", + help=( + "Clear output directory before creating packages." + ) + ) + + args = parser.parse_args(sys.argv[1:]) + main(args.output_dir, args.skip_zip, args.keep_sources, args.clear_output_dir) From 9c7ce75eea842ed60e53b70ba89a466c10049116 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 26 Oct 2023 12:27:07 +0000 Subject: [PATCH 13/15] chore(): update bug report / version --- .github/ISSUE_TEMPLATE/bug_report.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml index 3c126048da..b92061f39a 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.yml +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -35,6 +35,8 @@ body: label: Version description: What version are you running? Look to OpenPype Tray options: + - 3.17.4 + - 3.17.4-nightly.2 - 3.17.4-nightly.1 - 3.17.3 - 3.17.3-nightly.2 @@ -133,8 +135,6 @@ body: - 3.15.1-nightly.2 - 3.15.1-nightly.1 - 3.15.0 - - 3.15.0-nightly.1 - - 3.14.11-nightly.4 validations: required: true - type: dropdown From a6e72e708b5853f42aa99a18a57554ee2494d5ec Mon Sep 17 00:00:00 2001 From: Jakub Trllo Date: Thu, 26 Oct 2023 17:03:42 +0200 Subject: [PATCH 14/15] removed debugging prints --- server_addon/create_ayon_addons.py | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/server_addon/create_ayon_addons.py b/server_addon/create_ayon_addons.py index 47711244c3..711dc5d00a 100644 --- a/server_addon/create_ayon_addons.py +++ b/server_addon/create_ayon_addons.py @@ -274,24 +274,17 @@ def main(output_dir=None, skip_zip=True, keep_source=False, clear_output_dir=Fal root_dir = current_dir.parent create_zip = not skip_zip - output_dir = Path(output_dir) if output_dir else current_dir / "packages" - print("Current directory:", current_dir) - print("Root directory:", root_dir) - print("Skip zip:", skip_zip) - print("Clear output dir:", clear_output_dir) - print("Keep source:", keep_source) - print("Package creation started...") - print(f"Output directory: {output_dir}") # Make sure package dir is empty if output_dir.exists() and clear_output_dir: shutil.rmtree(str(output_dir)) + print("Package creation started...") + print(f"Output directory: {output_dir}") + # Make sure output dir is created output_dir.mkdir(parents=True, exist_ok=True) - for addon_dir in current_dir.iterdir(): - print(f"Processing addon: {addon_dir.name}") if not addon_dir.is_dir(): continue From afc980efb30207f510416ab3b8be2a7938a8a1d6 Mon Sep 17 00:00:00 2001 From: Jakub Trllo Date: Thu, 26 Oct 2023 17:07:24 +0200 Subject: [PATCH 15/15] small cleanup of the code and add option to limit addons creation --- server_addon/create_ayon_addons.py | 40 +++++++++++++++++++++++++----- 1 file changed, 34 insertions(+), 6 deletions(-) diff --git a/server_addon/create_ayon_addons.py b/server_addon/create_ayon_addons.py index 711dc5d00a..2f7be760f3 100644 --- a/server_addon/create_ayon_addons.py +++ b/server_addon/create_ayon_addons.py @@ -185,6 +185,9 @@ def create_openpype_package( addon_output_dir = output_dir / "openpype" / addon_version private_dir = addon_output_dir / "private" + if addon_output_dir.exists(): + shutil.rmtree(str(addon_output_dir)) + # Make sure dir exists addon_output_dir.mkdir(parents=True, exist_ok=True) private_dir.mkdir(parents=True, exist_ok=True) @@ -269,13 +272,22 @@ def create_addon_package( ) -def main(output_dir=None, skip_zip=True, keep_source=False, clear_output_dir=False): +def main( + output_dir=None, + skip_zip=True, + keep_source=False, + clear_output_dir=False, + addons=None, +): current_dir = Path(os.path.dirname(os.path.abspath(__file__))) root_dir = current_dir.parent create_zip = not skip_zip + if output_dir: + output_dir = Path(output_dir) + else: + output_dir = current_dir / "packages" - # Make sure package dir is empty if output_dir.exists() and clear_output_dir: shutil.rmtree(str(output_dir)) @@ -288,6 +300,9 @@ def main(output_dir=None, skip_zip=True, keep_source=False, clear_output_dir=Fal if not addon_dir.is_dir(): continue + if addons and addon_dir.name not in addons: + continue + server_dir = addon_dir / "server" if not server_dir.exists(): continue @@ -335,13 +350,26 @@ if __name__ == "__main__": ) ) parser.add_argument( - "-c", "--dont-clear-output", + "-c", "--clear-output-dir", dest="clear_output_dir", - action="store_false", + action="store_true", help=( - "Clear output directory before creating packages." + "Clear output directory before package creation." ) ) + parser.add_argument( + "-a", + "--addon", + dest="addons", + action="append", + help="Limit addon creation to given addon name", + ) args = parser.parse_args(sys.argv[1:]) - main(args.output_dir, args.skip_zip, args.keep_sources, args.clear_output_dir) + main( + args.output_dir, + args.skip_zip, + args.keep_sources, + args.clear_output_dir, + args.addons, + )