Edit report at https://bugs.php.net/bug.php?id=55348&edit=1
ID: 55348
Comment by: chris at cmbuckley dot co dot uk
Reported by: sprotte at visionconnect dot de
Summary: SoapServer (typemap related) "Error calling from_xml
callback"
Status: Open
Type: Bug
Package: SOAP related
Operating System: openSUSE 11.4
PHP Version: 5.3.7RC4
Block user comment: N
Private report: N
New Comment:
Description:
------------
Reduced to smaller test script.
Test script:
------------
http://starsquare.co.uk/code/php/bugs/55348.phps
Expected result:
----------------
...
<SOAP-ENV:Fault>
<faultcode>SOAP-ENV:Server</faultcode>
<faultstring>Conversion Fault</faultstring>
</SOAP-ENV:Fault>
...
Actual result:
--------------
Fatal error: SOAP-ERROR: Encoding: Error calling from_xml callback
Previous Comments:
------------------------------------------------------------------------
[2011-08-02 15:14:41] sprotte at visionconnect dot de
Description:
------------
Throwing a SoapFault exception inside the from_xml callback function (when
using the "typemap" feature with SoapServer) does not work as expected in some
cases.
I have created a small client/server application with one working example (type
"date") and one not working example (type "myType").
In case of the "date" type the SoapFault exception is transformed into a
matching SOAP-Response. The original message is available on the client side.
In case of the "myType" type the thrown SoapFault exception is completely
ignored and the SOAP-Response contains another error message.
Test script:
---------------
http://www.visionconnect.de/php_bugreports/soapserver_to_xml.tar.gz
Expected result:
----------------
Faultcode: 0001
Faultstring: Invalid date: 2011-15-15
Faultcode: 0002
Faultstring: Invalid type: foobar
Actual result:
--------------
Faultcode: 0001
Faultstring: Invalid date: 2011-15-15
Faultcode: SOAP-ENV:Server
Faultstring: SOAP-ERROR: Encoding: Error calling from_xml callback
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=55348&edit=1