suds: how to set proxy?

J

Johann Spies

According to the suds documentation I can set the proxy setting like this:

d = dict(http='host:80', https='host:443', ...)
client.set_options(proxy=d)

My problem is that you can only do that after 'client' was initiated like this:

client = Client(url)

And I need the proxy to reach the url.

I have tried the following ending in a SYN_SENT each time - ignoring
the proxy settings:

proxy = dict(http='proxy.sun.ac.za:3128', https='proxy.sun.ac.za:3128')

url = 'url_of_wdsl'
t = HttpAuthenticated()
client = Client(url, proxy = proxy, transport = t,
username='myusername', password='pw')

or

url = 'url_of_wdsl'
t = HttpAuthenticated()
client = Client(url, transport = t, username='myusername', password='pw')
client.set_options(proxy=proxy)

So how do I get suds to respect the proxy setting?

Regards
Johann
--
 May grace and peace be yours in abundance through the full knowledge
of God and of Jesus our Lord!  His divine power has given us
everything we need for life and godliness through the full knowledge
of the one who called us by his own glory and excellence.
                                                    2 Pet. 1:2b,3a
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,981
Messages
2,570,188
Members
46,733
Latest member
LonaMonzon

Latest Threads

Top