首页 文章

python ZEEP:SOAP响应中未将GUID从XML解析为JSON

提问于
浏览
0

我使用python的ZEEP库连接到SOAP Web服务,发现XML中返回的其中一个字段未正确解析 . 我已经从下面的XML响应中复制了片段,以及解析的JSON .

根据ZEEP文档中的说明,也可以参考https://gist.github.com/bsteverink/dede1f3341828d069a502f16ccc5da0b进行完整演示 .

我使用的是Zeep 2.0.0 .

从SOAP服务返回的片段:

<GetDataExchangeQueryResultRow>
    <DataType>System.Guid</DataType>
    <ReturnObject xmlns:q1="http://microsoft.com/wsdl/types/" xsi:type="q1:guid">16fed64c-9b6d-4383-bdd1-fd5cde084afe</ReturnObject>
    <DisplayName>Auto_ID</DisplayName>
</GetDataExchangeQueryResultRow>

来自客户端的JSON结果:

{
    'DataType': 'System.Guid',
    'ReturnObject': [],
    'DisplayName': 'Auto_ID'
}

任何提示和提示都会受到欢迎 .

1 回答

  • 0

    该库的作者指出我需要将库更新为github master .

相关问题