简体   繁体   English

Python Zeep Client请求在xml异常中引发错误

[英]Python Zeep Client request throws error in xml exception

When I run the following code, I keep getting the following error: here is an error in XML document (113, 25). ---> The string '' is not a valid Boolean value. 当我运行以下代码时, here is an error in XML document (113, 25). ---> The string '' is not a valid Boolean value.以下错误: here is an error in XML document (113, 25). ---> The string '' is not a valid Boolean value. here is an error in XML document (113, 25). ---> The string '' is not a valid Boolean value. I do not understand why this is happening. 我不明白为什么会这样。 Here is the documentation and according to it the boolean fields are not required. 是文档,根据该文档,不需要布尔字段。

from zeep import Client

client = Client('http://services.resumeparsing.com/ResumeService.asmx?wsdl')
response = client.service.ParseResume(request={'AccountId': 'XXXXXXX',\
    'ServiceKey':'XXXXXXXXX',\
    'FileBytes': file_bytes, 'FileText': file_text, \
    })
print(response)

Any help will be appreciated! 任何帮助将不胜感激!

Author of zeep here; zeep的作者在这里; which version are you using? 您正在使用哪个版本? It seems that zeep generates XML which is not valid according to the server. 似乎zeep根据服务器生成了无效的XML。

You can see which XML is sent by enabling the debug log level, see http://docs.python-zeep.org/en/latest/transport.html#debugging 您可以通过启用调试日志级别来查看发送的XML,请参阅http://docs.python-zeep.org/en/latest/transport.html#debugging

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM