runtime/eRPCServer.py
changeset 3898 de4f17d737a9
parent 3887 2df45e4bd500
child 3905 d47fe28d799a
equal deleted inserted replaced
3897:fc3621302cfe 3898:de4f17d737a9
    68     return_wrapper = ReturnWrappers.get(method_name,
    68     return_wrapper = ReturnWrappers.get(method_name,
    69         lambda method, args_wrapper, *args: method(*args_wrapper(*args)))
    69         lambda method, args_wrapper, *args: method(*args_wrapper(*args)))
    70 
    70 
    71     def exception_wrapper(self, *args):
    71     def exception_wrapper(self, *args):
    72         try:
    72         try:
    73             print("Srv "+method_name)
       
    74             return_wrapper(method, args_wrapper, *args)
    73             return_wrapper(method, args_wrapper, *args)
    75             return 0
    74             return 0
    76         except Exception as e:
    75         except Exception as e:
    77             print(traceback.format_exc())
    76             print(traceback.format_exc())
    78             PLCobj.LogMessage(CRITICAL_LOG_LEVEL, f'eRPC call {method_name} Exception "{str(e)}"')
    77             PLCobj.LogMessage(CRITICAL_LOG_LEVEL, f'eRPC call {method_name} Exception "{str(e)}"')