Skip to content
Snippets Groups Projects
Commit 0e589b63 authored by Thomas Juerges's avatar Thomas Juerges
Browse files

Call delete_device when there's a problem in init_device

parent e2b099b4
No related branches found
No related tags found
No related merge requests found
...@@ -98,6 +98,7 @@ class Crossecho(Device): ...@@ -98,6 +98,7 @@ class Crossecho(Device):
print("Connected to the OPC-UA server %s", self.OPC_Server_Name) print("Connected to the OPC-UA server %s", self.OPC_Server_Name)
except: except:
print("Failed to connect to the OPC-UA server %s. Traceback: %s", self.OPC_Server_Name, traceback.format_exc()) print("Failed to connect to the OPC-UA server %s. Traceback: %s", self.OPC_Server_Name, traceback.format_exc())
self.delete_device()
# PROTECTED REGION END # // Crossecho.init_device # PROTECTED REGION END # // Crossecho.init_device
def always_executed_hook(self): def always_executed_hook(self):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment