When I create an IMM object whose type in the xml file is SA_UINT32_T by using the Ccb API but the value input of the method "setattr()" is a string, an error will occur at the create() method.
Traceback (most recent call last):
File "opensaf-code/python/samples/ping-pong", line 78, in <module>
ccb.create(obj=obj)
File "/usr/local/lib/python3.6/dist-packages/pyosaf/utils/immom/ccb.py", line 189, in create
attr.attrValues = marshal_c_array(attr.attrValueType, values)
File "/usr/local/lib/python3.6/dist-packages/pyosaf/utils/immom/ccb.py", line 93, in marshal_c_array
c_array[i] = _value_to_ctype_ptr(value_type, value)
File "/usr/local/lib/python3.6/dist-packages/pyosaf/utils/immom/ccb.py", line 49, in _value_to_ctype_ptr
ctypeptr = cast(pointer(SaUint32T(value)), c_void_p)
TypeError: an integer is required (got type str)
commit 2cdd517578c86ce0f35b822d5845ea2c322fb490 (HEAD -> develop, origin/develop)
Author: khanh.q.nguyen1 khanh.q.nguyen1@dektech.com.au
Date: Mon May 22 16:03:34 2023 +0700
Related
Tickets:
#3338