[Fedora-suds-list] Error with Suds: error: suds.TypeNotFound: Type not found: 'BETRIEB'

Christian Klinger goschtl at googlemail.com
Fri Nov 20 12:23:58 UTC 2009


Hi

  i try to access a soap service with this script:

from suds.client import Client

def ga():
     client = Client('http://ws_mub_prod:8080/BETRWS.wsdl')
     print client
     BETRIEB_EING = client.factory.create('ETBSRV2-BETRWS-BETRIEB_EING')
     BETRIEB_EING = "0101010001"
     result = client.service.BETRWS(BETRIEB_EING)
     print result

The result/traceback of this script is this:

svcdrupanet01:/tmp/sudstest # bin/python sd.py

Suds ( https://fedorahosted.org/suds/ )  version: 0.3.7 GA  build: 
R580-20091016

Service ( BETRWS ) tns="http://namespaces.softwareag.com/entirex/xml/me"
    Prefixes (1)
       ns0 = "http://namespaces.softwareag.com/entirex/xml/me"
    Ports (1):
       (ETBSRV2Port)
          Methods (1):
             BETRWS(ETBSRV2-BETRWS-BETRIEB_EING BETRIEB_EING, )
          Types (2):
             ETBSRV2-BETRWS-Array
             ETBSRV2-BETRWS-BETRIEB_EING


No handlers could be found for logger "suds.umx.typed"
Traceback (most recent call last):
   File "sd.py", line 11, in ?
     print ga()
   File "sd.py", line 8, in ga
     result = client.service.BETRWS(BETRIEB_EING)
   File "/tmp/sudstest/suds/suds/client.py", line 535, in __call__
     return client.invoke(args, kwargs)
   File "/tmp/sudstest/suds/suds/client.py", line 595, in invoke
     result = self.send(msg)
   File "/tmp/sudstest/suds/suds/client.py", line 624, in send
     result = self.succeeded(binding, reply.message)
   File "/tmp/sudstest/suds/suds/client.py", line 656, in succeeded
     r, p = binding.get_reply(self.method, reply)
   File "/tmp/sudstest/suds/suds/bindings/binding.py", line 149, in 
get_reply
     result = self.replycomposite(rtypes, nodes)
   File "/tmp/sudstest/suds/suds/bindings/binding.py", line 206, in 
replycomposite
     sobject = unmarshaller.process(node, resolved)
   File "/tmp/sudstest/suds/suds/umx/typed.py", line 57, in process
     return Core.process(self, content)
   File "/tmp/sudstest/suds/suds/umx/core.py", line 48, in process
     data, result = self.append(content)
   File "/tmp/sudstest/suds/suds/umx/core.py", line 64, in append
     self.append_children(content)
   File "/tmp/sudstest/suds/suds/umx/core.py", line 141, in append_children
     cdata, cval = self.append(cont)
   File "/tmp/sudstest/suds/suds/umx/core.py", line 64, in append
     self.append_children(content)
   File "/tmp/sudstest/suds/suds/umx/core.py", line 141, in append_children
     cdata, cval = self.append(cont)
   File "/tmp/sudstest/suds/suds/umx/core.py", line 62, in append
     self.start(content)
   File "/tmp/sudstest/suds/suds/umx/typed.py", line 71, in start
     raise TypeNotFound(content.node.qname())
suds.TypeNotFound: Type not found: 'BETRIEB'


And here is the wsdl file:

<?xml version='1.0' ?>
<!-- Generated 13.09.2004 14:02:50 by Software AG SOAP Toolkit Wizard, 
Version 1.1 -->
<definitions name='ETBSRV2' 
targetNamespace='http://namespaces.softwareag.com/entirex/xml/me' 
xmlns='http://schemas.xmlsoap.org/wsdl/'
    xmlns:xsd='http://www.w3.org/2001/XMLSchema' 
xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/'
    xmlns:wsdl='http://schemas.xmlsoap.org/wsdl/'
    xmlns:SOAP-ENC='http://schemas.xmlsoap.org/soap/encoding/' 
xmlns:tns='http://namespaces.softwareag.com/entirex/xml/me'
 >
<types>
<schema 
targetNamespace='http://namespaces.softwareag.com/entirex/xml/me' 
xmlns='http://www.w3.org/2001/XMLSchema'>
<xsd:complexType name='ETBSRV2-BETRWS-BETRIEB_EING'>
<xsd:sequence>
<xsd:element name='P_KNR_E' type='xsd:string'/>
<xsd:element name='P_ISN_E' type='xsd:decimal'/>
<xsd:element name='P_NAME-1_E' type='xsd:string'/>
<xsd:element name='P_NAME-2_E' type='xsd:string'/>
<xsd:element name='P_NAME-3_E' type='xsd:string'/>
<xsd:element name='P_STRASSE_E' type='xsd:string'/>
<xsd:element name='P_HAUSNR_E' type='xsd:string'/>
<xsd:element name='P_PLZ_E' type='xsd:string'/>
<xsd:element name='P_ORT_E' type='xsd:string'/>
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name='ETBSRV2-BETRWS-Array'>
<xsd:sequence>
<xsd:element name='BETRIEB' minOccurs='1' maxOccurs='50'>
<xsd:complexType>
<xsd:sequence>
<xsd:element name='P_KNR' type='xsd:string'/>
<xsd:element name='P_NAME-1' type='xsd:string'/>
<xsd:element name='P_NAME-2' type='xsd:string'/>
<xsd:element name='P_NAME-3' type='xsd:string'/>
<xsd:element name='P_STRASSE' type='xsd:string'/>
<xsd:element name='P_HAUSNR' type='xsd:string'/>
<xsd:element name='P_PLZ' type='xsd:string'/>
<xsd:element name='P_ORT' type='xsd:string'/>
<xsd:element name='P_BV' type='xsd:string'/>
<xsd:element name='P_GEL' type='xsd:string'/>
<xsd:element name='P_SACHB' type='xsd:string'/>
<xsd:element name='P_TEL' type='xsd:string'/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:sequence>
</xsd:complexType>
</schema>
</types>
<message name='BETRWS'>
<part name='BETRIEB_EING' type='tns:ETBSRV2-BETRWS-BETRIEB_EING'/>
</message>
<message name='BETRWSResponse'>
<part name='Array' type='tns:ETBSRV2-BETRWS-Array'/>
<part name='P_ISN_E' type='xsd:decimal'/>
</message>
<portType name='ETBSRV2Port'>
<operation name='BETRWS'>
<input message='tns:BETRWS'/>
<output message='tns:BETRWSResponse'/>
</operation>
</portType>
<binding name='ETBSRV2SoapBinding' type='tns:ETBSRV2Port'>
<soap:binding style='rpc' transport='http://schemas.xmlsoap.org/soap/http'/>
<operation name='BETRWS'>
<soap:operation soapAction='BETRWS'/>
<input>
<soap:body use='encoded' 
encodingStyle='http://schemas.xmlsoap.org/soap/encoding/'
                namespace='urn:com-softwareag-entirex-rpc:ETBSRV2'
                />
</input>
<output>
<soap:body use='encoded' 
encodingStyle='http://schemas.xmlsoap.org/soap/encoding/'
                namespace='urn:com-softwareag-entirex-rpc:ETBSRV2'
                />
</output>
</operation>
</binding>
<service name='BETRWS'>
<port name='ETBSRV2Port' binding='tns:ETBSRV2SoapBinding'>
<soap:address location='http://ws_mub_prod:8080/WS_7.2.1p50'/>
</port>
</service>
</definitions>


Thanks for your help....
If you need more information please ask.

Christian




More information about the suds mailing list