doMain
121 print(client.call("TestRpcInt.Echo123", ["A1", "B2", "C3"]))
122 print(client.call("TestRpcInt.EchoStruct", {"A" :"Aa", "B":"Bb", "C":"Cc"}))
123
124def doMain(args):125 if len(args) == 2 and args[0] == "testdata":
126 build_test_data(args[1])
127 elif len(args) == 3 and args[0] == "rpc-server":
doRpcClientToGoSvc
114# print("\t>>>> Port is not open")
115# sock.close()
116
117def doRpcClientToGoSvc(port):118 # doCheckSocket(port)
119 address = msgpackrpc.Address(mylocaladdr, port)
120 client = msgpackrpc.Client(address, unpack_encoding='utf-8')
doRpcClientToPythonSvc
98 t.start()
99 server.start()
100
101def doRpcClientToPythonSvc(port):102 address = msgpackrpc.Address(mylocaladdr, port)
103 client = msgpackrpc.Client(address, unpack_encoding='utf-8')
104 print(client.call("Echo123", "A1", "B2", "C3"))
EchoStruct
84 class EchoHandler(object):
85 def Echo123(self, msg1, msg2, msg3):
86 return ("1:%s 2:%s 3:%s" % (msg1.decode("utf-8"), msg2.decode("utf-8"), msg3.decode("utf-8")))
87 def EchoStruct(self, msg): 88 return ("%s" % msg)
89
90 addr = msgpackrpc.Address(mylocaladdr, port)
Echo123
82
83def doRpcServer(port, stopTimeSec):
84 class EchoHandler(object):
85 def Echo123(self, msg1, msg2, msg3): 86 return ("1:%s 2:%s 3:%s" % (msg1.decode("utf-8"), msg2.decode("utf-8"), msg3.decode("utf-8")))
87 def EchoStruct(self, msg):
88 return ("%s" % msg)
The module/function docstring is missing.
If you want to ignore this, you can configure this in the .deepsource.toml
file. Please refer to docs for available options.