rxhttp icon indicating copy to clipboard operation
rxhttp copied to clipboard

新版本3.3.0http返回xml就回调到onFailure 里面了 但是xml是正常数据正常返回的

Open DotMatrixDev1024 opened this issue 1 year ago • 6 comments

DotMatrixDev1024 avatar Oct 12 '24 01:10 DotMatrixDev1024

RxHttp.postBody()
    .setBody(wfsBody, Param.HTTP_CONTENT_TYPE.toMediaType())
    .toAwaitString()
    .awaitResult {
                    
    }
    .onFailure {
                   
    }

DotMatrixDev1024 avatar Oct 12 '24 01:10 DotMatrixDev1024

贴出返回数据及日志

liujingxing avatar Oct 12 '24 03:10 liujingxing

返回数据

<?xml version="1.0" encoding="UTF-8"?>
<wfs:TransactionResponse
    xmlns:xs=""
    xmlns:wfs="http://www.opengis.net/wfs"
    xmlns:gml="http://www.opengis.net/gml"
    xmlns:ogc="http://www.opengis.net/ogc"
    xmlns:ows="http://www.opengis.net/ows"
    xmlns:xlink="http://www.w3.org/1999/xlink"
    xmlns:xsi="" version="1.1.0" xsi:schemaLocation="">
    <wfs:TransactionSummary>
        <wfs:totalInserted>0</wfs:totalInserted>
        <wfs:totalUpdated>1</wfs:totalUpdated>
        <wfs:totalDeleted>0</wfs:totalDeleted>
    </wfs:TransactionSummary>
    <wfs:TransactionResults/>
    <wfs:InsertResults>
        <wfs:Feature>
            <ogc:FeatureId fid="none"/>
        </wfs:Feature>
    </wfs:InsertResults>
</wfs:TransactionResponse>

DotMatrixDev1024 avatar Oct 12 '24 06:10 DotMatrixDev1024

贴上日志,看看啥异常

liujingxing avatar Oct 12 '24 09:10 liujingxing

3.2.7没问题 3.3.0有问题 代码没动 我用string按理可以让接收任意string吧 这直接转json 又不是所有请求都会返回json

image

DotMatrixDev1024 avatar Oct 12 '24 13:10 DotMatrixDev1024

看了下,是有问题,3.3.0版本改一个需求引起的,这样看来,应该是要还原回去

liujingxing avatar Oct 13 '24 13:10 liujingxing