Regarding node functions throwing exceptions when applied on nodes.
Hi Colleagues,
I am trying to read data_types , values etc for some nodes using getter and setter function on nodes of NODE TYPE VARIABLES.
I am getting the data type and values when applied on some nodes, but facing errors and getting exceptions when applied for some other nodes.
I am using node.get_data_type_as_variant_type() , node.get_data_type() , node.get_data_value() ,etc all other functions of nodes , and when i apply on some nodes i am getting issue and exceptions are raised as added below .


Is there any other way to get the DATA TYPE of the TAG other than node.get_data_type_as_variant_type() ?
It would be great if anyone from the group can help me out on the above issues.
Thanks Rajnish Vishwakarma
What TAG do you mean? Is that the NodeId (it looks like that)?
If you got a Node, you can read out the DataType attribute, which contains "Identifier" which is a number. What you may looking for is: https://github.com/FreeOpcUa/python-opcua/blob/13b4e1249e06a3d3feef09afd04139eb774207bc/opcua/common/node.py#L88
That number represents a Datatype e.g. Double = 11.
Is that what you are looking for?