Discussion:
Bug #47584 [Asn->Fbk]: WSDL error in soapClient causes Fatal Error
(too old to reply)
d***@php.net
2010-09-02 08:40:35 UTC
Permalink
Edit report at http://bugs.php.net/bug.php?id=47584&edit=1

ID: 47584
Updated by: ***@php.net
Reported by: gem at rellim dot com
Summary: WSDL error in soapClient causes Fatal Error
-Status: Assigned
+Status: Feedback
Type: Bug
Package: SOAP related
Operating System: Linux
PHP Version: 5.2.9
Assigned To: dmitry
Block user comment: N

New Comment:

BTW despite SoapClient emits a fatal error it already throws exception
which can be caught (even in 5.2 brunch).

<?php
try {
$x = new SoapClient("non-existent.wsdl");
} catch (Exception $e) {
}
echo "ok\n";'
?>


Previous Comments:
------------------------------------------------------------------------
[2010-06-24 01:55:11] gem at rellim dot com

This is a still a 100% show stopper for me. I can not make PHP pages
live
that will crash on simple network errors.

------------------------------------------------------------------------
[2010-06-22 10:35:23] florent dot biville at insa-rouen dot fr

I can confirm I encounter the same problem.
Despite everything documented, problems with WSDL reading will trigger a
fatal error.

------------------------------------------------------------------------
[2010-04-09 07:41:35] pwb at evanr dot com

This is a real issue, even when the SoapClient is set to throw
exceptions and not
errors. This fatal error cannot be defeated even with the exceptions
option set
to true.

We're experiencing this in 5.2.13 on linux x64.

A fatal error is thrown not only when WSDL can't be loaded but as well
when an
internal reference in the WSDL (e.g. to a namespace) cannot be
imported/resolved.

------------------------------------------------------------------------
[2009-03-06 17:49:08] gem at rellim dot com

Why does it work OK for you and not for me? Just because it
works on one host for you does not mean it does not fail for me.

This is the entire program to reproduce:
<?php
$client = new soapClient('http://google.com');
?>

PHP Fatal error: SOAP-ERROR: Parsing WSDL: XXXX

I can reproduce on several different hosts. I am not
running Xdebug, eaccelerator, or any other add in.

------------------------------------------------------------------------
[2009-03-06 15:32:18] ***@php.net

It already works that way.

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

http://bugs.php.net/bug.php?id=47584
--
Edit this bug report at http://bugs.php.net/bug.php?id=47584&edit=1
gem at rellim dot com
2010-09-02 17:14:25 UTC
Permalink
Edit report at http://bugs.php.net/bug.php?id=47584&edit=1

ID: 47584
Comment by: gem at rellim dot com
Reported by: gem at rellim dot com
Summary: WSDL error in soapClient causes Fatal Error
Status: Feedback
Type: Bug
Package: SOAP related
Operating System: Linux
PHP Version: 5.2.9
Assigned To: dmitry
Block user comment: N

New Comment:

Your example fails for me, I can not catch the error:

# cat tmp.php
<?php
try {
$x = new SoapClient("non-existent.wsdl");
} catch (Exception $e) {
}
echo "ok\n";
?>



# php tmp.php
PHP Warning: SoapClient::SoapClient(): I/O warning : failed to load
external
entity "non-existent.wsdl" in /tmp/tmp.php on line 3
PHP Stack trace:
PHP 1. {main}() /tmp/tmp.php:0
PHP 2. SoapClient->SoapClient() /tmp/tmp.php:3
PHP Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from 'non-
existent.wsdl' : failed to load external entity "non-existent.wsdl"
in /tmp/tmp.php on line 3
PHP Stack trace:
PHP 1. {main}() /tmp/tmp.php:0
PHP 2. SoapClient->SoapClient() /tmp/tmp.php:3
#


Previous Comments:
------------------------------------------------------------------------
[2010-09-02 10:40:34] ***@php.net

BTW despite SoapClient emits a fatal error it already throws exception
which can be caught (even in 5.2 brunch).

<?php
try {
$x = new SoapClient("non-existent.wsdl");
} catch (Exception $e) {
}
echo "ok\n";'
?>

------------------------------------------------------------------------
[2010-06-24 01:55:11] gem at rellim dot com

This is a still a 100% show stopper for me. I can not make PHP pages
live
that will crash on simple network errors.

------------------------------------------------------------------------
[2010-06-22 10:35:23] florent dot biville at insa-rouen dot fr

I can confirm I encounter the same problem.
Despite everything documented, problems with WSDL reading will trigger a
fatal error.

------------------------------------------------------------------------
[2010-04-09 07:41:35] pwb at evanr dot com

This is a real issue, even when the SoapClient is set to throw
exceptions and not
errors. This fatal error cannot be defeated even with the exceptions
option set
to true.

We're experiencing this in 5.2.13 on linux x64.

A fatal error is thrown not only when WSDL can't be loaded but as well
when an
internal reference in the WSDL (e.g. to a namespace) cannot be
imported/resolved.

------------------------------------------------------------------------
[2009-03-06 17:49:08] gem at rellim dot com

Why does it work OK for you and not for me? Just because it
works on one host for you does not mean it does not fail for me.

This is the entire program to reproduce:
<?php
$client = new soapClient('http://google.com');
?>

PHP Fatal error: SOAP-ERROR: Parsing WSDL: XXXX

I can reproduce on several different hosts. I am not
running Xdebug, eaccelerator, or any other add in.

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

http://bugs.php.net/bug.php?id=47584
--
Edit this bug report at http://bugs.php.net/bug.php?id=47584&edit=1
gem at rellim dot com
2010-09-02 17:15:23 UTC
Permalink
Edit report at http://bugs.php.net/bug.php?id=47584&edit=1

ID: 47584
Comment by: gem at rellim dot com
Reported by: gem at rellim dot com
Summary: WSDL error in soapClient causes Fatal Error
Status: Feedback
Type: Bug
Package: SOAP related
Operating System: Linux
PHP Version: 5.2.9
Assigned To: dmitry
Block user comment: N

New Comment:

Forgot my version details:

# php -v
PHP 5.3.3 (cli) (built: Jul 26 2010 14:55:07)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
with eAccelerator v0.9.6, Copyright (c) 2004-2010 eAccelerator, by
eAccelerator
with Xdebug v2.1.0, Copyright (c) 2002-2010, by Derick Rethans


Previous Comments:
------------------------------------------------------------------------
[2010-09-02 19:14:24] gem at rellim dot com

Your example fails for me, I can not catch the error:

# cat tmp.php
<?php
try {
$x = new SoapClient("non-existent.wsdl");
} catch (Exception $e) {
}
echo "ok\n";
?>



# php tmp.php
PHP Warning: SoapClient::SoapClient(): I/O warning : failed to load
external
entity "non-existent.wsdl" in /tmp/tmp.php on line 3
PHP Stack trace:
PHP 1. {main}() /tmp/tmp.php:0
PHP 2. SoapClient->SoapClient() /tmp/tmp.php:3
PHP Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from 'non-
existent.wsdl' : failed to load external entity "non-existent.wsdl"
in /tmp/tmp.php on line 3
PHP Stack trace:
PHP 1. {main}() /tmp/tmp.php:0
PHP 2. SoapClient->SoapClient() /tmp/tmp.php:3
#

------------------------------------------------------------------------
[2010-09-02 10:40:34] ***@php.net

BTW despite SoapClient emits a fatal error it already throws exception
which can be caught (even in 5.2 brunch).

<?php
try {
$x = new SoapClient("non-existent.wsdl");
} catch (Exception $e) {
}
echo "ok\n";'
?>

------------------------------------------------------------------------
[2010-06-24 01:55:11] gem at rellim dot com

This is a still a 100% show stopper for me. I can not make PHP pages
live
that will crash on simple network errors.

------------------------------------------------------------------------
[2010-06-22 10:35:23] florent dot biville at insa-rouen dot fr

I can confirm I encounter the same problem.
Despite everything documented, problems with WSDL reading will trigger a
fatal error.

------------------------------------------------------------------------
[2010-04-09 07:41:35] pwb at evanr dot com

This is a real issue, even when the SoapClient is set to throw
exceptions and not
errors. This fatal error cannot be defeated even with the exceptions
option set
to true.

We're experiencing this in 5.2.13 on linux x64.

A fatal error is thrown not only when WSDL can't be loaded but as well
when an
internal reference in the WSDL (e.g. to a namespace) cannot be
imported/resolved.

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

http://bugs.php.net/bug.php?id=47584
--
Edit this bug report at http://bugs.php.net/bug.php?id=47584&edit=1
gem at rellim dot com
2010-09-02 17:20:22 UTC
Permalink
Edit report at http://bugs.php.net/bug.php?id=47584&edit=1

ID: 47584
Comment by: gem at rellim dot com
Reported by: gem at rellim dot com
Summary: WSDL error in soapClient causes Fatal Error
Status: Feedback
Type: Bug
Package: SOAP related
Operating System: Linux
PHP Version: 5.2.9
Assigned To: dmitry
Block user comment: N

New Comment:

Hmm, on 2nd look, it does now appear catchable w/o XDebug, but not with
XDebug.

Ideas?


Previous Comments:
------------------------------------------------------------------------
[2010-09-02 19:17:36] gem at rellim dot com

It fails similarly without XDebug:

# php -v
PHP 5.3.3 (cli) (built: Jul 26 2010 14:55:07)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
with eAccelerator v0.9.6, Copyright (c) 2004-2010 eAccelerator, by
eAccelerator

# php tmp.php
PHP Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from 'non-
existent.wsdl' : failed to load external entity "non-existent.wsdl"
in /tmp/tmp.php on line 3
ok

#

------------------------------------------------------------------------
[2010-09-02 19:15:22] gem at rellim dot com

Forgot my version details:

# php -v
PHP 5.3.3 (cli) (built: Jul 26 2010 14:55:07)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
with eAccelerator v0.9.6, Copyright (c) 2004-2010 eAccelerator, by
eAccelerator
with Xdebug v2.1.0, Copyright (c) 2002-2010, by Derick Rethans

------------------------------------------------------------------------
[2010-09-02 19:14:24] gem at rellim dot com

Your example fails for me, I can not catch the error:

# cat tmp.php
<?php
try {
$x = new SoapClient("non-existent.wsdl");
} catch (Exception $e) {
}
echo "ok\n";
?>



# php tmp.php
PHP Warning: SoapClient::SoapClient(): I/O warning : failed to load
external
entity "non-existent.wsdl" in /tmp/tmp.php on line 3
PHP Stack trace:
PHP 1. {main}() /tmp/tmp.php:0
PHP 2. SoapClient->SoapClient() /tmp/tmp.php:3
PHP Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from 'non-
existent.wsdl' : failed to load external entity "non-existent.wsdl"
in /tmp/tmp.php on line 3
PHP Stack trace:
PHP 1. {main}() /tmp/tmp.php:0
PHP 2. SoapClient->SoapClient() /tmp/tmp.php:3
#

------------------------------------------------------------------------
[2010-09-02 10:40:34] ***@php.net

BTW despite SoapClient emits a fatal error it already throws exception
which can be caught (even in 5.2 brunch).

<?php
try {
$x = new SoapClient("non-existent.wsdl");
} catch (Exception $e) {
}
echo "ok\n";'
?>

------------------------------------------------------------------------
[2010-06-24 01:55:11] gem at rellim dot com

This is a still a 100% show stopper for me. I can not make PHP pages
live
that will crash on simple network errors.

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

http://bugs.php.net/bug.php?id=47584
--
Edit this bug report at http://bugs.php.net/bug.php?id=47584&edit=1
r***@php.net
2010-09-02 17:22:02 UTC
Permalink
Edit report at http://bugs.php.net/bug.php?id=47584&edit=1

ID: 47584
Updated by: ***@php.net
Reported by: gem at rellim dot com
Summary: WSDL error in soapClient causes Fatal Error
Status: Feedback
Type: Bug
Package: SOAP related
Operating System: Linux
PHP Version: 5.2.9
Assigned To: dmitry
Block user comment: N

New Comment:

It is a catchable fatal though.

eg.

<?php
try {
$x = @new SoapClient("non-existent.wsdl",array("exceptions" => 1));

} catch (SoapFault $E) {
echo $E->faultstring;
}
echo "ok\n";


Previous Comments:
------------------------------------------------------------------------
[2010-09-02 19:20:22] gem at rellim dot com

Hmm, on 2nd look, it does now appear catchable w/o XDebug, but not with
XDebug.

Ideas?

------------------------------------------------------------------------
[2010-09-02 19:17:36] gem at rellim dot com

It fails similarly without XDebug:

# php -v
PHP 5.3.3 (cli) (built: Jul 26 2010 14:55:07)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
with eAccelerator v0.9.6, Copyright (c) 2004-2010 eAccelerator, by
eAccelerator

# php tmp.php
PHP Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from 'non-
existent.wsdl' : failed to load external entity "non-existent.wsdl"
in /tmp/tmp.php on line 3
ok

#

------------------------------------------------------------------------
[2010-09-02 19:15:22] gem at rellim dot com

Forgot my version details:

# php -v
PHP 5.3.3 (cli) (built: Jul 26 2010 14:55:07)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
with eAccelerator v0.9.6, Copyright (c) 2004-2010 eAccelerator, by
eAccelerator
with Xdebug v2.1.0, Copyright (c) 2002-2010, by Derick Rethans

------------------------------------------------------------------------
[2010-09-02 19:14:24] gem at rellim dot com

Your example fails for me, I can not catch the error:

# cat tmp.php
<?php
try {
$x = new SoapClient("non-existent.wsdl");
} catch (Exception $e) {
}
echo "ok\n";
?>



# php tmp.php
PHP Warning: SoapClient::SoapClient(): I/O warning : failed to load
external
entity "non-existent.wsdl" in /tmp/tmp.php on line 3
PHP Stack trace:
PHP 1. {main}() /tmp/tmp.php:0
PHP 2. SoapClient->SoapClient() /tmp/tmp.php:3
PHP Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from 'non-
existent.wsdl' : failed to load external entity "non-existent.wsdl"
in /tmp/tmp.php on line 3
PHP Stack trace:
PHP 1. {main}() /tmp/tmp.php:0
PHP 2. SoapClient->SoapClient() /tmp/tmp.php:3
#

------------------------------------------------------------------------
[2010-09-02 10:40:34] ***@php.net

BTW despite SoapClient emits a fatal error it already throws exception
which can be caught (even in 5.2 brunch).

<?php
try {
$x = new SoapClient("non-existent.wsdl");
} catch (Exception $e) {
}
echo "ok\n";'
?>

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

http://bugs.php.net/bug.php?id=47584
--
Edit this bug report at http://bugs.php.net/bug.php?id=47584&edit=1
gem at rellim dot com
2010-09-02 19:10:09 UTC
Permalink
Edit report at http://bugs.php.net/bug.php?id=47584&edit=1

ID: 47584
User updated by: gem at rellim dot com
Reported by: gem at rellim dot com
Summary: WSDL error in soapClient causes Fatal Error
Status: Bogus
Type: Bug
Package: SOAP related
Operating System: Linux
PHP Version: 5.2.9
Assigned To: dmitry
Block user comment: N

New Comment:

I was a confirmed bug in earlier versions. So it should be 'Fixed' not
"Bogus'.


Previous Comments:
------------------------------------------------------------------------
[2010-09-02 19:37:13] ***@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.

------------------------------------------------------------------------
[2010-09-02 19:34:19] gem at rellim dot com

I do see it catchable now without XDebug.

# php tmp.php
SOAP-ERROR: Parsing WSDL: Couldn't load from 'non-existent.wsdl' :
failed to load
external entity "non-existent.wsdl"
ok

#

------------------------------------------------------------------------
[2010-09-02 19:33:05] gem at rellim dot com

Not catchable for me with XDebug and your example:


# cat tmp.php
<?php
try {
$x = @new SoapClient("non-existent.wsdl",array("exceptions" => 1));

} catch (SoapFault $E) {
echo $E->faultstring;
}
echo "ok\n";

?>

# php tmp.php
#

------------------------------------------------------------------------
[2010-09-02 19:22:02] ***@php.net

It is a catchable fatal though.

eg.

<?php
try {
$x = @new SoapClient("non-existent.wsdl",array("exceptions" => 1));

} catch (SoapFault $E) {
echo $E->faultstring;
}
echo "ok\n";

------------------------------------------------------------------------
[2010-09-02 19:20:22] gem at rellim dot com

Hmm, on 2nd look, it does now appear catchable w/o XDebug, but not with
XDebug.

Ideas?

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

http://bugs.php.net/bug.php?id=47584
--
Edit this bug report at http://bugs.php.net/bug.php?id=47584&edit=1
gem at rellim dot com
2010-09-02 17:17:36 UTC
Permalink
Edit report at http://bugs.php.net/bug.php?id=47584&edit=1

ID: 47584
Comment by: gem at rellim dot com
Reported by: gem at rellim dot com
Summary: WSDL error in soapClient causes Fatal Error
Status: Feedback
Type: Bug
Package: SOAP related
Operating System: Linux
PHP Version: 5.2.9
Assigned To: dmitry
Block user comment: N

New Comment:

It fails similarly without XDebug:

# php -v
PHP 5.3.3 (cli) (built: Jul 26 2010 14:55:07)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
with eAccelerator v0.9.6, Copyright (c) 2004-2010 eAccelerator, by
eAccelerator

# php tmp.php
PHP Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from 'non-
existent.wsdl' : failed to load external entity "non-existent.wsdl"
in /tmp/tmp.php on line 3
ok

#


Previous Comments:
------------------------------------------------------------------------
[2010-09-02 19:15:22] gem at rellim dot com

Forgot my version details:

# php -v
PHP 5.3.3 (cli) (built: Jul 26 2010 14:55:07)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
with eAccelerator v0.9.6, Copyright (c) 2004-2010 eAccelerator, by
eAccelerator
with Xdebug v2.1.0, Copyright (c) 2002-2010, by Derick Rethans

------------------------------------------------------------------------
[2010-09-02 19:14:24] gem at rellim dot com

Your example fails for me, I can not catch the error:

# cat tmp.php
<?php
try {
$x = new SoapClient("non-existent.wsdl");
} catch (Exception $e) {
}
echo "ok\n";
?>



# php tmp.php
PHP Warning: SoapClient::SoapClient(): I/O warning : failed to load
external
entity "non-existent.wsdl" in /tmp/tmp.php on line 3
PHP Stack trace:
PHP 1. {main}() /tmp/tmp.php:0
PHP 2. SoapClient->SoapClient() /tmp/tmp.php:3
PHP Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from 'non-
existent.wsdl' : failed to load external entity "non-existent.wsdl"
in /tmp/tmp.php on line 3
PHP Stack trace:
PHP 1. {main}() /tmp/tmp.php:0
PHP 2. SoapClient->SoapClient() /tmp/tmp.php:3
#

------------------------------------------------------------------------
[2010-09-02 10:40:34] ***@php.net

BTW despite SoapClient emits a fatal error it already throws exception
which can be caught (even in 5.2 brunch).

<?php
try {
$x = new SoapClient("non-existent.wsdl");
} catch (Exception $e) {
}
echo "ok\n";'
?>

------------------------------------------------------------------------
[2010-06-24 01:55:11] gem at rellim dot com

This is a still a 100% show stopper for me. I can not make PHP pages
live
that will crash on simple network errors.

------------------------------------------------------------------------
[2010-06-22 10:35:23] florent dot biville at insa-rouen dot fr

I can confirm I encounter the same problem.
Despite everything documented, problems with WSDL reading will trigger a
fatal error.

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

http://bugs.php.net/bug.php?id=47584
--
Edit this bug report at http://bugs.php.net/bug.php?id=47584&edit=1
gem at rellim dot com
2010-09-02 17:33:05 UTC
Permalink
Edit report at http://bugs.php.net/bug.php?id=47584&edit=1

ID: 47584
Comment by: gem at rellim dot com
Reported by: gem at rellim dot com
Summary: WSDL error in soapClient causes Fatal Error
Status: Feedback
Type: Bug
Package: SOAP related
Operating System: Linux
PHP Version: 5.2.9
Assigned To: dmitry
Block user comment: N

New Comment:

Not catchable for me with XDebug and your example:


# cat tmp.php
<?php
try {
$x = @new SoapClient("non-existent.wsdl",array("exceptions" => 1));

} catch (SoapFault $E) {
echo $E->faultstring;
}
echo "ok\n";

?>

# php tmp.php
#


Previous Comments:
------------------------------------------------------------------------
[2010-09-02 19:22:02] ***@php.net

It is a catchable fatal though.

eg.

<?php
try {
$x = @new SoapClient("non-existent.wsdl",array("exceptions" => 1));

} catch (SoapFault $E) {
echo $E->faultstring;
}
echo "ok\n";

------------------------------------------------------------------------
[2010-09-02 19:20:22] gem at rellim dot com

Hmm, on 2nd look, it does now appear catchable w/o XDebug, but not with
XDebug.

Ideas?

------------------------------------------------------------------------
[2010-09-02 19:17:36] gem at rellim dot com

It fails similarly without XDebug:

# php -v
PHP 5.3.3 (cli) (built: Jul 26 2010 14:55:07)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
with eAccelerator v0.9.6, Copyright (c) 2004-2010 eAccelerator, by
eAccelerator

# php tmp.php
PHP Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from 'non-
existent.wsdl' : failed to load external entity "non-existent.wsdl"
in /tmp/tmp.php on line 3
ok

#

------------------------------------------------------------------------
[2010-09-02 19:15:22] gem at rellim dot com

Forgot my version details:

# php -v
PHP 5.3.3 (cli) (built: Jul 26 2010 14:55:07)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
with eAccelerator v0.9.6, Copyright (c) 2004-2010 eAccelerator, by
eAccelerator
with Xdebug v2.1.0, Copyright (c) 2002-2010, by Derick Rethans

------------------------------------------------------------------------
[2010-09-02 19:14:24] gem at rellim dot com

Your example fails for me, I can not catch the error:

# cat tmp.php
<?php
try {
$x = new SoapClient("non-existent.wsdl");
} catch (Exception $e) {
}
echo "ok\n";
?>



# php tmp.php
PHP Warning: SoapClient::SoapClient(): I/O warning : failed to load
external
entity "non-existent.wsdl" in /tmp/tmp.php on line 3
PHP Stack trace:
PHP 1. {main}() /tmp/tmp.php:0
PHP 2. SoapClient->SoapClient() /tmp/tmp.php:3
PHP Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from 'non-
existent.wsdl' : failed to load external entity "non-existent.wsdl"
in /tmp/tmp.php on line 3
PHP Stack trace:
PHP 1. {main}() /tmp/tmp.php:0
PHP 2. SoapClient->SoapClient() /tmp/tmp.php:3
#

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

http://bugs.php.net/bug.php?id=47584
--
Edit this bug report at http://bugs.php.net/bug.php?id=47584&edit=1
gem at rellim dot com
2010-09-02 17:34:19 UTC
Permalink
Edit report at http://bugs.php.net/bug.php?id=47584&edit=1

ID: 47584
Comment by: gem at rellim dot com
Reported by: gem at rellim dot com
Summary: WSDL error in soapClient causes Fatal Error
Status: Feedback
Type: Bug
Package: SOAP related
Operating System: Linux
PHP Version: 5.2.9
Assigned To: dmitry
Block user comment: N

New Comment:

I do see it catchable now without XDebug.

# php tmp.php
SOAP-ERROR: Parsing WSDL: Couldn't load from 'non-existent.wsdl' :
failed to load
external entity "non-existent.wsdl"
ok

#


Previous Comments:
------------------------------------------------------------------------
[2010-09-02 19:33:05] gem at rellim dot com

Not catchable for me with XDebug and your example:


# cat tmp.php
<?php
try {
$x = @new SoapClient("non-existent.wsdl",array("exceptions" => 1));

} catch (SoapFault $E) {
echo $E->faultstring;
}
echo "ok\n";

?>

# php tmp.php
#

------------------------------------------------------------------------
[2010-09-02 19:22:02] ***@php.net

It is a catchable fatal though.

eg.

<?php
try {
$x = @new SoapClient("non-existent.wsdl",array("exceptions" => 1));

} catch (SoapFault $E) {
echo $E->faultstring;
}
echo "ok\n";

------------------------------------------------------------------------
[2010-09-02 19:20:22] gem at rellim dot com

Hmm, on 2nd look, it does now appear catchable w/o XDebug, but not with
XDebug.

Ideas?

------------------------------------------------------------------------
[2010-09-02 19:17:36] gem at rellim dot com

It fails similarly without XDebug:

# php -v
PHP 5.3.3 (cli) (built: Jul 26 2010 14:55:07)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
with eAccelerator v0.9.6, Copyright (c) 2004-2010 eAccelerator, by
eAccelerator

# php tmp.php
PHP Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from 'non-
existent.wsdl' : failed to load external entity "non-existent.wsdl"
in /tmp/tmp.php on line 3
ok

#

------------------------------------------------------------------------
[2010-09-02 19:15:22] gem at rellim dot com

Forgot my version details:

# php -v
PHP 5.3.3 (cli) (built: Jul 26 2010 14:55:07)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
with eAccelerator v0.9.6, Copyright (c) 2004-2010 eAccelerator, by
eAccelerator
with Xdebug v2.1.0, Copyright (c) 2002-2010, by Derick Rethans

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

http://bugs.php.net/bug.php?id=47584
--
Edit this bug report at http://bugs.php.net/bug.php?id=47584&edit=1
r***@php.net
2010-09-02 17:37:13 UTC
Permalink
Edit report at http://bugs.php.net/bug.php?id=47584&edit=1

ID: 47584
Updated by: ***@php.net
Reported by: gem at rellim dot com
Summary: WSDL error in soapClient causes Fatal Error
-Status: Feedback
+Status: Bogus
Type: Bug
Package: SOAP related
Operating System: Linux
PHP Version: 5.2.9
Assigned To: dmitry
Block user comment: N

New Comment:

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.


Previous Comments:
------------------------------------------------------------------------
[2010-09-02 19:34:19] gem at rellim dot com

I do see it catchable now without XDebug.

# php tmp.php
SOAP-ERROR: Parsing WSDL: Couldn't load from 'non-existent.wsdl' :
failed to load
external entity "non-existent.wsdl"
ok

#

------------------------------------------------------------------------
[2010-09-02 19:33:05] gem at rellim dot com

Not catchable for me with XDebug and your example:


# cat tmp.php
<?php
try {
$x = @new SoapClient("non-existent.wsdl",array("exceptions" => 1));

} catch (SoapFault $E) {
echo $E->faultstring;
}
echo "ok\n";

?>

# php tmp.php
#

------------------------------------------------------------------------
[2010-09-02 19:22:02] ***@php.net

It is a catchable fatal though.

eg.

<?php
try {
$x = @new SoapClient("non-existent.wsdl",array("exceptions" => 1));

} catch (SoapFault $E) {
echo $E->faultstring;
}
echo "ok\n";

------------------------------------------------------------------------
[2010-09-02 19:20:22] gem at rellim dot com

Hmm, on 2nd look, it does now appear catchable w/o XDebug, but not with
XDebug.

Ideas?

------------------------------------------------------------------------
[2010-09-02 19:17:36] gem at rellim dot com

It fails similarly without XDebug:

# php -v
PHP 5.3.3 (cli) (built: Jul 26 2010 14:55:07)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
with eAccelerator v0.9.6, Copyright (c) 2004-2010 eAccelerator, by
eAccelerator

# php tmp.php
PHP Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from 'non-
existent.wsdl' : failed to load external entity "non-existent.wsdl"
in /tmp/tmp.php on line 3
ok

#

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

http://bugs.php.net/bug.php?id=47584
--
Edit this bug report at http://bugs.php.net/bug.php?id=47584&edit=1
Loading...