kartagis / pysimplesoap

Automatically exported from code.google.com/p/pysimplesoap
0 stars 0 forks source link

Version 1.05 fails where 1.02 worked #52

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
The attached WSDL file worked with version 1.02 of pysimplesoap. When upgrading 
to 1.05, it doesn't work anymore. 

This is the XML it sent with version 1.02 when doing the get operation:
<?xml version="1.0" encoding="UTF-8"?><soap:Envelope 
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" 
xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soap:Body>
    <get xmlns="urn:dws">
    </get>
</soap:Body>
</soap:Envelope>

And this is what it sends with version 1.05:
<?xml version="1.0" encoding="UTF-8"?><soap:Envelope 
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" 
xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soap:Header/>
<soap:Body>

</soap:Body>
</soap:Envelope>

With version 1.02, the service gets parsed as follows:
>>> pprint.pprint(c.services)
{u'dws': {'documentation': '',
          'ports': {u'dws': {'location': u'http://10.11.12.13:10011',
                             'operations': {u'add': {'documentation': u'Service definition of function ns__add',
                                                     'input': {'add': *{u'ipin': <type 'str'>, u'portin': <type 'int'>, u'ipout': <type 'str'>, u'portout': <type 'int'>}*},
                                                     'name': u'add',
                                                     'output': {'addResponse': *{u'result': <type 'int'>}*}},
                                            u'get': {'documentation': u'Service definition of function ns__get',
                                                     'input': {'get': None},
                                                     'name': u'get',
                                                     'output': {'getResponse': [*{u'result': *{u'id': <type 'int'>, u'ipin': <type 'str'>, u'portin': <type 'int'>, u'ipout': <type 'str'>, u'portout': <type 'int'>, u'status': <type 'bool'>}*}*]}},
                                            u'getBuildVersion': {'documentation': u'Service definition of function ns__getBuildVersion',
                                                                 'input': {'getBuildVersion': None},
                                                                 'name': u'getBuildVersion',
                                                                 'output': {'getBuildVersionResponse': *{u'result': <type 'str'>}*}},
                                            u'rem': {'documentation': u'Service definition of function ns__rem',
                                                     'input': {'rem': *{u'id': <type 'int'>}*},
                                                     'name': u'rem',
                                                     'output': {'remResponse': *{u'result': <type 'int'>}*}}},
                             'port_type_name': 'dwsPortType',
                             'service_name': u'dws',
                             'soap_uri': u'http://schemas.xmlsoap.org/wsdl/soap/',
                             'soap_ver': 'soap11',
                             'transport': u'http://schemas.xmlsoap.org/soap/http'}}}}

While version 1.05 parses it like this:
>>> pprint.pprint(c.services)
{u'dws': {'documentation': '',
          'ports': {u'dws': {'location': u'http://10.11.12.13:10011',
                             'operations': {u'add': {'documentation': u'Service definition of function ns__add',
                                                     'header': {'add': *{u'ipin': <type 'unicode'>, u'portin': <type 'int'>, u'ipout': <type 'unicode'>, u'portout': <type 'int'>}*},
                                                     'input': {'add': *{u'ipin': <type 'unicode'>, u'portin': <type 'int'>, u'ipout': <type 'unicode'>, u'portout': <type 'int'>}*},
                                                     'name': u'add',
                                                     'output': {'addResponse': *{u'result': <type 'int'>}*},
                                                     'parts': {'input_body': u'parameters',
                                                               'input_header': None,
                                                               'output_body': u'parameters',
                                                               'output_header': None}},
                                            u'get': {'documentation': u'Service definition of function ns__get',
                                                     'header': {u'getRequest': {u'parameters': None}},
                                                     'input': {u'getRequest': {u'parameters': None}},
                                                     'name': u'get',
                                                     'output': {'getResponse': [*{u'result': *{u'id': <type 'int'>, u'ipin': <type 'unicode'>, u'portin': <type 'int'>, u'ipout': <type 'unicode'>, u'portout': <type 'int'>, u'status': <type 'bool'>}*}*]},
                                                     'parts': {'input_body': u'parameters',
                                                               'input_header': None,
                                                               'output_body': u'parameters',
                                                               'output_header': None}},
                                            u'getBuildVersion': {'documentation': u'Service definition of function ns__getBuildVersion',
                                                                 'header': {u'getBuildVersionRequest': {u'parameters': None}},
                                                                 'input': {u'getBuildVersionRequest': {u'parameters': None}},
                                                                 'name': u'getBuildVersion',
                                                                 'output': {'getBuildVersionResponse': *{u'result': <type 'unicode'>}*},
                                                                 'parts': {'input_body': u'parameters',
                                                                           'input_header': None,
                                                                           'output_body': u'parameters',
                                                                           'output_header': None}},
                                            u'rem': {'documentation': u'Service definition of function ns__rem',
                                                     'header': {'rem': *{u'id': <type 'int'>}*},
                                                     'input': {'rem': *{u'id': <type 'int'>}*},
                                                     'name': u'rem',
                                                     'output': {'remResponse': *{u'result': <type 'int'>}*},
                                                     'parts': {'input_body': u'parameters',
                                                               'input_header': None,
                                                               'output_body': u'parameters',
                                                               'output_header': None}}},
                             'port_type_name': 'dwsPortType',
                             'service_name': u'dws',
                             'soap_uri': u'http://schemas.xmlsoap.org/wsdl/soap/',
                             'soap_ver': 'soap11',
                             'transport': u'http://schemas.xmlsoap.org/soap/http'}}}}

Original issue reported on code.google.com by ismael...@gmail.com on 9 Feb 2012 at 2:21

Attachments:

GoogleCodeExporter commented 8 years ago
In newer versions, you have to pass soap_server='jbossas6' or similar to pass 
empty parameters, could you try it?

Original comment by reingart@gmail.com on 18 Apr 2012 at 7:43

GoogleCodeExporter commented 8 years ago
Passing soap_server="oracle" works. Thanks.

Original comment by ismael...@gmail.com on 18 Apr 2012 at 8:06

GoogleCodeExporter commented 8 years ago
Ok, thanks for the confirmation!

Original comment by reingart@gmail.com on 18 Apr 2012 at 8:13