Req #65779 [Com]: Downgrade network error in SoapClient to E_WARNING
| From: | chris at kotret dot yourweb dot de | Date: | Fri, 11 Oct 2013 12:20:10 +0000 |
| Subject: | Req #65779 [Com]: Downgrade network error in SoapClient to E_WARNING | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-182129@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=65779&edit=1
ID: 65779
Comment by: chris at kotret dot yourweb dot de
Reported by: xfra35 at gmail dot com
Summary: Downgrade network error in SoapClient to E_WARNING
Status: Open
Type: Feature/Change Request
Package: SOAP related
Operating System: Any
PHP Version: 5.5.4
Block user comment: N
Private report: N
New Comment:
also: if Exceptions are set to true there should be no error thrown at all but an Exception. This is
a serious bug with no possible workaround.
Chris
Previous Comments:
------------------------------------------------------------------------
[2013-09-28 07:21:04] xfra35 at gmail dot com
Description:
------------
Could you please downgrade the error raised by the SoapClient constructor when the
provided wsdl file cannot be found from E_ERROR to E_WARNING? A network error is
not fatal.
This issue has been discussed many times but was mixed with other issues (like
xdebug interference..) and at the end nothing was done. Cf.
https://bugs.php.net/bug.php?id=47584#1283456233:
> [2010-09-02 19:37 UTC] rasmus@php.net
> Right, so this is not a PHP bug. Perhaps a feature request to downgrade that
> particular error to a Warning instead of a catchable fatal, but that is all I
see.
Test script:
---------------
$client=@new \SoapClient('garbage',array('exceptions'=>FALSE));
echo 'OK';
Expected result:
----------------
We should see "OK",
Actual result:
--------------
If we use register_shutdown_function to display the contents of error_get_last(),
we get:
Array
(
[type] => 1
[message] => SOAP-ERROR: Parsing WSDL: Couldn't load from 'garbage' : failed
to load external entity "garbage"
)
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=65779&edit=1