私はSOAP Webサービスを(サービスはASP.netで書かれている)を呼び出すことSudsを使用して次のような単純なPythonのテストスクリプトがあります。パイソン/泡:タイプが見つかりません: 'XS:complexTypeの'
from suds.client import Client
url = 'http://someURL.asmx?WSDL'
client = Client(url)
result = client.service.GetPackageDetails("MyPackage" )
print result
を
私は、このテストスクリプトを実行すると(それがラップしていないとして使用されるコードのマークアップ)私は、次のエラーを取得しています:
(合わせて再フォーマット)WSDLファイルのヘッダのソースを見るとNo handlers could be found for logger "suds.bindings.unmarshaller"
Traceback (most recent call last):
File "sudsTest.py", line 9, in <module>
result = client.service.GetPackageDetails("t3db" )
File "build/bdist.cygwin-1.5.25-i686/egg/suds/client.py", line 240, in __call__
File "build/bdist.cygwin-1.5.25-i686/egg/suds/client.py", line 379, in call
File "build/bdist.cygwin-1.5.25-i686/egg/suds/client.py", line 240, in __call__
File "build/bdist.cygwin-1.5.25-i686/egg/suds/client.py", line 422, in call
File "build/bdist.cygwin-1.5.25-i686/egg/suds/client.py", line 480, in invoke
File "build/bdist.cygwin-1.5.25-i686/egg/suds/client.py", line 505, in send
File "build/bdist.cygwin-1.5.25-i686/egg/suds/client.py", line 537, in succeeded
File "build/bdist.cygwin-1.5.25-i686/egg/suds/bindings/binding.py", line 149, in get_reply
File "build/bdist.cygwin-1.5.25-i686/egg/suds/bindings/unmarshaller.py", line 303, in process
File "build/bdist.cygwin-1.5.25-i686/egg/suds/bindings/unmarshaller.py", line 88, in process
File "build/bdist.cygwin-1.5.25-i686/egg/suds/bindings/unmarshaller.py", line 104, in append
File "build/bdist.cygwin-1.5.25-i686/egg/suds/bindings/unmarshaller.py", line 181, in append_children
File "build/bdist.cygwin-1.5.25-i686/egg/suds/bindings/unmarshaller.py", line 104, in append
File "build/bdist.cygwin-1.5.25-i686/egg/suds/bindings/unmarshaller.py", line 181, in append_children
File "build/bdist.cygwin-1.5.25-i686/egg/suds/bindings/unmarshaller.py", line 104, in append
File "build/bdist.cygwin-1.5.25-i686/egg/suds/bindings/unmarshaller.py", line 181, in append_children
File "build/bdist.cygwin-1.5.25-i686/egg/suds/bindings/unmarshaller.py", line 102, in append
File "build/bdist.cygwin-1.5.25-i686/egg/suds/bindings/unmarshaller.py", line 324, in start
suds.TypeNotFound: Type not found: 'xs:complexType'
:
<?xml version="1.0" encoding="utf-8" ?>
<wsdl:definitions xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:s="http://www.w3.org/2001/XMLSchema"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:tns="http://http://someInternalURL/webservices.asmx"
xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/"
xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
targetNamespace="http://someURL.asmx"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
私は、スキーマを修正するためにシュッドの
doctor classを使用する必要がありますが、私はニーズが私の場合には、固定内容を正確に把握していないSOAPの初心者であること
suds.TypeNotFound: Type not found: 'xs:complexType'
:私は、出力の最後の行に基づいて推測してい
。スキッドを修正/修正するためにSudsを使っている人はいますか?
シンプルなC#テストアプリケーションを試したところ、このサービスに接続できます(ただし、サービスはASP.netベースです)。 Sudsがデフォルトでサポートしていないマイクロソフト固有のものかもしれませんか? – Danielb
サービスがDataSetを返そうとしているようです。私はロガーで次のように見ています: 警告:suds.bindings.unmarshaller:属性(IsDataSet)タイプ、見つからない 警告:suds.bindings.unmarshaller:属性(タイプ)タイプ、見つからない エラー:suds .bindings.unmarshaller:Schema:0x7fce048c – Danielb
SUDSのようなサウンドは、データセットの構造を指定するタグからインポートされません。 WSDLでインポートを検索しましたか? それが答えであれば、SUDSのImportDoctorが助けてくれます。例:https://fedorahosted.org/suds/wiki/Documentation#FIXINGBROKENSCHEMAs –
ewall