State:Closed|icon_bug|icon_katana|database:public|Resolution:Fixed|BugID:330272|TargetRelease:3.0v1|
Problem summary
The forceArray hint is currently only respected on string attributes of GenericAssign XML node types, not number attributes.
Additionally, it can only be specified as strings 'True' or 'False', not any other boolean-like values. This should be modified in GenericAssign.py.
Steps to reproduce
<args format='1.0' scope='/root' fixedCEL='/root'> <float name='number' default='0.5'/> <string name='text' /> <float name='numberArrayQuestionMark' default='0.5' forceArray='True'/> <string name='textArrayQuestionMark' forceArray='True' /></args>
Save the file as ForceArrayDemo.xml in a GenericAssign folder in KATANA_RESOURCES.
Launch Katana and create a ForceArrayDemo node
Inspect the parameter types by running the following code in the Python tab:
print(NodegraphAPI.GetNode('ForceArrayDemo').getParameter('args.number').getXML())
print(NodegraphAPI.GetNode('ForceArrayDemo').getParameter('args.text').getXML())
print(NodegraphAPI.GetNode('ForceArrayDemo').getParameter('args.numberArrayQuestionMark').getXML())
print(NodegraphAPI.GetNode('ForceArrayDemo').getParameter('args.textArrayQuestionMark').getXML())
Result: numberArrayQuestionMark is a simple number parameter when it should be a number array. textArrayQuestionMark is a string array parameter as expected.
Workaround
Unknown
Reproduced by support
Katana 2.6v3 - Windows 7
This issue is present in all versions of the product.
Expected behaviour
The float parameter with the forceArray hint set to True should be created as a numberArray parameter.
Actual behaviour
It is created as a simple number parameter.
We're sorry to hear that
Please tell us why