Hello
I'm trying to make a web service client in python, and so to start out, I found this simple example that are supposed to parse an wsdl file using SOAPPy. I'm using Windows and got SOAPPy installed using the Enthought Python Distribution. I've tried several wsdl files and commenting out parts of the code etc. but I just can't twist my head around what's the problem here. Any help would be greatly appreciated. soappyTest.py: - from SOAPpy import WSDL
-
-
url = 'GoogleSearch.wsdl' # from http://api.google.com/GoogleSearch.wsdl
-
-
# just use the path to the wsdl of your choice
-
wsdlObject = WSDL.Proxy(url + '?WSDL')
-
-
print 'Available methods:'
-
for method in wsdlObject.methods.keys() :
-
print method
-
ci = wsdlObject.methods[method]
-
# you can also use ci.inparams
-
for param in ci.outparams :
-
# list of the function and type
-
# depending of the wsdl...
-
print param.name.ljust(20) , param.type
-
print
-
output at command prompt / terminal: - Traceback (most recent call last):
-
File "C:\jostein\matlab_med_webservice\soappyTest.py", line 6, in <module>
-
wsdlObject = WSDL.Proxy(url + '?WSDL')
-
File "C:\Python25\lib\site-packages\soappy-0.11.6.0001-py2.5-win32.egg\SOAPpy\WSDL.py", line 67, in __init__
-
self.wsdl = reader.loadFromString(str(wsdlsource))
-
File "C:\Python25\lib\site-packages\soappy-0.11.6.0001-py2.5-win32.egg\SOAPpy\wstools\WSDLTools.py", line 47, in loadFromString
-
return self.loadFromStream(StringIO(data))
-
File "C:\Python25\lib\site-packages\soappy-0.11.6.0001-py2.5-win32.egg\SOAPpy\wstools\WSDLTools.py", line 28, in loadFromStream
-
document = DOM.loadDocument(stream)
-
File "C:\Python25\lib\site-packages\soappy-0.11.6.0001-py2.5-win32.egg\SOAPpy\wstools\Utility.py", line 572, in loadDocument
-
return xml.dom.minidom.parse(data)
-
File "C:\Python25\lib\site-packages\pyxml-0.8.4.0002-py2.5-win32.egg\_xmlplus\dom\minidom.py", line 1915, in parse
-
return expatbuilder.parse(file)
-
File "C:\Python25\lib\site-packages\pyxml-0.8.4.0002-py2.5-win32.egg\_xmlplus\dom\expatbuilder.py", line 930, in parse
-
result = builder.parseFile(file)
-
File "C:\Python25\lib\site-packages\pyxml-0.8.4.0002-py2.5-win32.egg\_xmlplus\dom\expatbuilder.py", line 207, in parseFile
-
parser.Parse(buffer, 0)
-
xml.parsers.expat.ExpatError: syntax error: line 1, column 0
Thanks in advance for any help!
0 1953 Sign in to post your reply or Sign up for a free account.
Similar topics
by: Doug Farrell |
last post by:
Hi everyone,
I'm trying to build a program to interface to a SOAP/XML interface
provided by one of our vendors. This interface is built with MS SOAP
Toolkit 3.0, so I'm guessig they are running...
|
by: Vivek |
last post by:
Hi,
Can anyone provide me with sample code that will allow me to use
SOAPpy with a WSDL file using HTTP basic authentication? The only
thing I've been able to find on the net is...
|
by: Harry George |
last post by:
I'm trying to setup a SOAPpy service under xinetd. Has someone done
this sort of thing? Didn't find it from google searches or
documentation. This is probably a sockets-level issue, but I was...
|
by: m.banaouas |
last post by:
Hello Pythoneers:
I would like to ask you a simple question:
Are you satisfied by SOAPpy module?
Actually, I use this module since a year and i immediately found it very
well-implemented,...
|
by: Steve |
last post by:
Hi All,
I have a Python script that uses SOAPpy and I'm outputting all of the
methods and info about the parameters... I'm having trouble getting
information out of the __init__ parameter.
...
|
by: icius |
last post by:
Hello all,
I am trying to use a web services API with Python and SOAPpy as a
client. Some of the method paramters in this web service's WSDL are
asking for an "ArrayOfString" type. Here is my...
|
by: Steve |
last post by:
Hi All,
What are the required version of the SOAPpy, PyXML, fpconst that are
needed to run under the Python 2.5 environment on Windows?
Locations for the downloads?
Thanks!
Steve
|
by: linuxprog |
last post by:
hi all
i'm building a webservice client with soappy
when i send some informations it's returns an error
here is the informations that generates the error
var = SOAPpy.structType()...
|
by: Alex Ezell |
last post by:
Can anyone offer any assistance as to how to convert a basic python
dictionary, list, or even tuple into the SOAP type "ArrayOfKeyValue"?
I am currently using SOAPpy, but would be willing to...
|
by: neridaj |
last post by:
Hello,
I'm going through the SOAP Web Services portion of Mark Pilgrim's
tutorial and I'm getting this error when trying to build:
python setup.py build
Traceback (most recent call last):...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: aa123db |
last post by:
Variable and constants
Use var or let for variables and const fror constants.
Var foo ='bar';
Let foo ='bar';const baz ='bar';
Functions
function $name$ ($parameters$) {
}
...
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
by: ryjfgjl |
last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
| |