service = ServiceProxy(url) print "Service is : ",service print service.__dict__
print 'Before Value' value = service.myMethod('Aditi') print 'After Value'
print value -----------------------------------------------------------
After running command
>python webServiceTry.py
I am getting following output/error
----------------------------------------------------------- <Z SI.wstools.WSDLTools.WSDL instance at 0x009D7C38>
Service is : <ZSI.ServiceProxy.ServiceProxy instance at 0x00CBC6C0>
{'_wsdl': <ZSI.wstools.WSDLTools.WSDL instance at 0x009D7C38>, '_tracefile': None, 'myName': <ZSI.ServiceProxy.MethodProxy instance at 0x00CBC828>, '_port': <ZSI.wstools.WSDLTools.Port instance at 0x0 0CBC5F8>, '_nsdict': {}, '_transdict': None, '_name': u'MyServiceService', '_service': <ZSI.wstools.WSDLTools.Service instance at 0x00CBC580>, '__doc__': '', 'myMethod': <ZSI.ServiceProxy.MethodProxy instance at 0x00CBC760>}
Traceback (most recent call last): File "webServiceTry.py", line 18, in ? value = service.myMethod('Aditi') File "C:\Python24\lib\site-packages\ZSI\ServiceProxy.py", line 292, in __call__ return self.parent()._call(self.__name__, *args, **kwargs) File "C:\Python24\lib\site-packages\ZSI\ServiceProxy.py", line 85, in _call request, response = self._getTypeCodes(callinfo) File "C:\Python24\lib\site-packages\ZSI\ServiceProxy.py", line 127, in _getTypeCodes request.oname = '%(prefix)s:%(name)s xmlns:%(prefix)s="%(namespaceURI)s"' \ AttributeError: Struct instance has no attribute 'oname'