plt-tud / opc_ua_xml_export_client

OPC UA Node XML export client
GNU General Public License v3.0
22 stars 14 forks source link

Xml import timeout #4

Open gauss345 opened 1 year ago

gauss345 commented 1 year ago

I'm trying to generate a nodeset xml from a s7-1500 ( siemens plc ), that has a lot of nodes, and I'm getting a time out. I've tried also to see if I could do this via uaexpert but this has limits unless you pay a subscription, and then I'm not sure it will work either/better.

I'm actually only interested in a specific namespace, but it seems the tool, first imports all the address space, and then selects only that address space you specify in the command line to be exported.

Without having to do this work myself now :( , is there a tool that can do the above for me, or should I modify this tool ?

below is the timeout error.

INFO:__main__:Add ns=3;s="DB_Css01DaqiSendData"."udtDaten"."arData"[3893]
INFO:__main__:Add ns=3;s="DB_Css01DaqiSendData"."udtDaten"."arData"[3894]
INFO:__main__:Add ns=3;s="DB_Css01DaqiSendData"."udtDaten"."arData"[3895]
INFO:__main__:Add ns=3;s="DB_Css01DaqiSendData"."udtDaten"."arData"[3896]
Traceback (most recent call last):
  File "NodeXmlExporter.py", line 124, in <module>
    exporter.import_nodes(server_url=args.serverUrl)
  File "NodeXmlExporter.py", line 82, in import_nodes
    self.iterater_over_child_nodes(root)
  File "NodeXmlExporter.py", line 27, in iterater_over_child_nodes
    self.iterater_over_child_nodes(child)
  File "NodeXmlExporter.py", line 27, in iterater_over_child_nodes
    self.iterater_over_child_nodes(child)
  File "NodeXmlExporter.py", line 27, in iterater_over_child_nodes
    self.iterater_over_child_nodes(child)
  [Previous line repeated 5 more times]
  File "NodeXmlExporter.py", line 25, in iterater_over_child_nodes
    for child in node.get_children(refs=33):
  File "/home/lcp/.local/share/virtualenvs/opc_ua_xml_export_client-UitYIB7z/lib/python3.8/site-packages/opcua/common/node.py", line 316, in get_children
    return self.get_referenced_nodes(refs, ua.BrowseDirection.Forward, nodeclassmask)
  File "/home/lcp/.local/share/virtualenvs/opc_ua_xml_export_client-UitYIB7z/lib/python3.8/site-packages/opcua/common/node.py", line 390, in get_referenced_nodes
    references = self.get_references(refs, direction, nodeclassmask, includesubtypes)
  File "/home/lcp/.local/share/virtualenvs/opc_ua_xml_export_client-UitYIB7z/lib/python3.8/site-packages/opcua/common/node.py", line 369, in get_references
    results = self.server.browse(params)
  File "/home/lcp/.local/share/virtualenvs/opc_ua_xml_export_client-UitYIB7z/lib/python3.8/site-packages/opcua/client/ua_client.py", line 327, in browse
    data = self._uasocket.send_request(request)
  File "/home/lcp/.local/share/virtualenvs/opc_ua_xml_export_client-UitYIB7z/lib/python3.8/site-packages/opcua/client/ua_client.py", line 83, in send_request
    data = future.result(self.timeout)
  File "/home/lcp/.pyenv/versions/3.8.16/lib/python3.8/concurrent/futures/_base.py", line 446, in result
    raise TimeoutError()
concurrent.futures._base.TimeoutError
sheinze commented 1 year ago

Hey @gauss345 , i just used the newest version to export the nodeset from an profinet gateway and it worked flawlessly. Can you check with the most current version if the issue is still relevant?