Daniele: this is definitely a pain. Here's what I use, and it works fine on
Windows 7 and python 2.7. I've found that pathname2url in the urllib module
helps make this easier. See if something like this helps:
from urllib import pathname2url
url = 'file:' + pathname2url(directory +'\\' + wsdl)
Where directory looks like "C:\\tmp" and wsdl is the actual name of the
WSDL.
On another note, I've noticed that the Win 7 / 2.7 setup runs *much* more
slowly than on XP, and obviously Linux. But I sense that it's probably
another post for another time :).
Good luck!
-Matt Cauthorn
On Wed, Mar 2, 2011 at 12:37 PM, daniele visaggio <
visaggio.daniele(a)gmail.com> wrote:
Hi all,
my problem is the following:
###################################################################
from suds.client import Client
from suds.sax.element import Element
wsdl = 'file:\\\E:\\schema\\6.0\\AXLAPI.wsdl'
client = Client(wsdl, location="https://1.1.1.1:8443/axl/
",username='usernamel',password='password')
Traceback (most recent call last):
File "<pyshell#6>", line 1, in <module>
client = Client(wsdl, location="https://10.129.93.135:8443/axl/
",username='Admin_axl',password='massimo')
File "build\bdist.win32\egg\suds\client.py", line 112, in __init__
self.wsdl = reader.open(url)
File "build\bdist.win32\egg\suds\reader.py", line 152, in open
d = self.fn(url, self.options)
File "build\bdist.win32\egg\suds\wsdl.py", line 158, in __init__
self.resolve()
File "build\bdist.win32\egg\suds\wsdl.py", line 207, in resolve
c.resolve(self)
File "build\bdist.win32\egg\suds\wsdl.py", line 491, in resolve
qref = qualify(op.input, self.root, definitions.tns)
File "build\bdist.win32\egg\suds\xsd\__init__.py", line 56, in qualify
raise Exception('prefix (%s) not resolved' % p)
Exception: prefix (s0) not resolved
###################################################################
As you can see, i'm not able to open the wsdl file stored on my disk. I've
already tried various versions of the path stored in the variable called
wsdl, like
wsdl = 'file:///C://schema//6.0//AXLAPI.wsdl'
I don't understand what this error means:
Exception('prefix (%s) not resolved' % p)
Exception: prefix (s0) not resolved
Can you help me please?
Kind regards,
Daniele
_______________________________________________
suds mailing list
suds(a)lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/suds