I had to developed an application which will communicate with a Web service via python. I have to run this code on a Windows server machine for some reasons (which i am not much experianced with, notmally we use uint based systems).
My communication with the api provider is not directly because of some communication issies. So i have to mail my problems to another person and he email them my message in the native language, so i could not get much support from the provider because of that.
My problem is, i use suds for web service client. Cleint semmed to succeed to get WSDL definition from the serveer like:
from suds.client import Client
class SomeClass(Client):
def __init__(self):
Client.__init__(url)
def myFunc():
f = SomeClass()
print f
Service ( transport ) tns=”…”
Prefixes (1) ns0 = ….
Ports (2): (TransportSoap) Methods (4) GetBalance()…
So i can see that suds can reach target web service and get the WSDL file. However when i call a method like:
def myFunc():
f = SomeClass()
f.GetBalance()
Urllib2.URLError <urlopen error [Errno 10060] A connection attempt
failed because the connected party did not properly respond after a
period of time, or established connection failed because connected
host has failed to respond>
I could not see what is wrong?
After some search based on
urlopen error [Errno 10060], i decided to try proxy usage and it turns out to be the solution!If WSDL url is
then using:
definitely solves the problem…