Open MustafaJafar opened 6 months ago
Problem 1: inventory tool tells the wrong count.
Also, removing the instances from the inventory tool, doesn't uninstall the HDA. Which means I can still able to create as much as HDAs and inventory tool won't know.
This could be solved by ON publish and saving of the HDA secretly imprint it with the parms needed for the containerization (like give it the representation id, etc.) so that if you just create it - it has those attributes.
So, I found a solution for this one.
We can programmatically add a onCreated
script. (we only to run this code once, maybe we can add it to the HDA Creator plugin.)
here's a snippet:
import hou
hda_node = hou.node('/obj/AVALON_CONTAINERS/SOPS/hou_hdas_hou_hdas_Test_1')
hda_def = hda_node.type().definition()
hda_def.addSection(
"OnCreated",
"""
print("Hey, I exist. Say my name:", kwargs['node'])
"""
)
hda_def.setExtraFileOption("OnCreated/IsPython", True)
and in that onCreated
script we add some logic to add the necessary AYON parameters, it will replace this logic in the loader.
I'd recommend to use generic code in the onCreated
script so that artists are free to use the HDA outside of AYON.
Is there an existing issue for this?
Current Behavior:
By default Houdini doesn't install the published HDAs until a user load them from load tool. When an HDA is installed, it becomes available to be loaded via TAB menu. HDAs loaded from TAB menu are not tracked by the load tool.
Problem 1: inventory tool tells the wrong count.
Also, removing the instances from the inventory tool, doesn't uninstall the HDA. Which means I can still able to create as much as HDAs and inventory tool won't know.
But tbh, when updating the definition of an HDA. it's set in the Houdini session for this node type. which means Houdini will automatically update any instance of that node. which also means that count table should be grayed out because updating one instance will also update all the instances (Houdini default).
Problem 2: updating one HDA instance updates all the HDAs because we are updating the HDA definition. So, we need that limitation to be visible in the inventory tool.
Expected Behavior:
Personally, I expect :
Version
1.0.0
What platform you are running on?
Windows
Steps To Reproduce:
In Houdini: Problem 1: inventory tool tells the wrong count.
Problem 2: updating one HDA instance updates all the HDAs because we are updating the HDA definition. So, we need that limitation to be visible in the inventory tool.
Are there any labels you wish to add?
Relevant log output:
No response
Additional context:
No response
[cuID:AY-5262]