[xslt] bug? warning given as error
- From: S Woodside <sbwoodside yahoo com>
- To: axkit-users axkit org, xslt gnome org
- Subject: [xslt] bug? warning given as error
- Date: Tue, 22 Apr 2003 21:11:26 -0400
This seems like a possible bug in Apache::AxKit::Provider::File. For a
document() call on a non-existing file, xsltproc gives a warning, on
the same test files AxKit gives an error.
Using libxml 20506, libxslt 10029 and libexslt 719
AxKit 1.6.1
I generated a simple testcase.
=========================
test.xml
=========================
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="test.xsl" ?>
<foo>bar</foo>
=========================
test.xsl
=========================
<?xml version="1.0"?>
<xsl:stylesheet
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0">
<xsl:output method = "html" />
<xsl:template match="/">
<xsl:value-of select="'foo'"/>
<xsl:value-of select="document('test.xml')"/> <!-- *** -->
</xsl:template>
</xsl:stylesheet>
=========================
Output in xsltproc & AxKit
=========================
foobar
=========================
Error condition
=========================
Change the line marked with *** to:
<xsl:value-of select="document('test.xmlasdfa')"/> <!-- *** -->
=========================
Output in xsltproc
=========================
% xsltproc test.xml
warning: failed to load external entity "test.xmasdfl"
foo
=========================
Output in AxKit
=========================
...
[Tue Apr 22 21:00:30 2003] [warn] [client 127.0.0.1] [AxKit] [LibXSLT]
performing transformation
[Tue Apr 22 21:00:30 2003] [warn] [client 127.0.0.1] [AxKit] LibXSLT
match_uri: /test.xmasdfl
[Tue Apr 22 21:00:30 2003] [warn] [client 127.0.0.1] [AxKit] LibXSLT
open_content_uri: /test.xmasdfl
[Tue Apr 22 21:00:30 2003] [warn] [client 127.0.0.1] [AxKit] Content
Provider Override: Apache::AxKit::Provider::File
[Tue Apr 22 21:00:30 2003] [warn] [client 127.0.0.1] [AxKit] decoding
from UTF-8
[Tue Apr 22 21:00:30 2003] [warn] [client 127.0.0.1] [AxKit] [req] File
Provider given $r: /Library/WebServer/Apache2/test.xmasdfl
[Tue Apr 22 21:00:30 2003] [warn] [client 127.0.0.1] [AxKit] encoding
to UTF-8
[Tue Apr 22 21:00:30 2003] [warn] [client 127.0.0.1] [AxKit] Caught an
exception
[Tue Apr 22 21:00:30 2003] [error] [client 127.0.0.1] [AxKit]
[UnCaught] File '/Library/WebServer/Apache2/test.xmasdfl' does not
exist or is not readable
[Tue Apr 22 21:00:30 2003] [error] [client 127.0.0.1] [AxKit]
[Backtrace] File '/Library/WebServer/Apache2/test.xmasdfl' does not
exist or is not readable at /Library/Perl/Error.pm line 148
Error::throw('Apache::AxKit::Exception::IO', '-text', 'File
\'/Library/WebServer/Apache2/test.xmasdfl\' does not exist ...') called
at /Library/Perl/darwin/Apache/AxKit/Provider/File.pm line 215
Apache::AxKit::Provider::File::get_fh('Apache::AxKit::Provider::File=HAS
H(0x4b18c4)') called at
/Library/Perl/darwin/Apache/AxKit/Provider/File.pm line 239
Apache::AxKit::Provider::File::get_strref('Apache::AxKit::Provider::File
=HASH(0x4b18c4)') called at
/Library/Perl/darwin/Apache/AxKit/Language/LibXSLT.pm line 180
Apache::AxKit::Language::LibXSLT::open_content_uri('/test.xmasdfl')
called at /Library/Perl/darwin/Apache/AxKit/Language/LibXSLT.pm line 122
Apache::AxKit::Language::LibXSLT::handler('Apache::AxKit::Language::LibX
SLT', 'AxKit::Apache=SCALAR(0x499518)',
'Apache::AxKit::Provider::File=HASH(0x497f28)',
'Apache::AxKit::Provider::File=HASH(0x147320)', 1) called at
/Library/Perl/darwin/AxKit.pm line 739
AxKit::process_request('AxKit::Apache=SCALAR(0x499518)',
'Apache::AxKit::Provider::File=HASH(0x497f28)', 'ARRAY(0xa629c8)',
undef) called at /Library/Perl/darwin/AxKit.pm line 461
AxKit::run_axkit_engine('AxKit::Apache=SCALAR(0x499518)',
'Apache::AxKit::Provider::File=HASH(0x497f28)') called at
/Library/Perl/darwin/AxKit.pm line 288
eval {...} called at /Library/Perl/darwin/AxKit.pm line 279
AxKit::main_handler('AxKit::Apache=SCALAR(0x499518)',
'Apache::AxKit::Provider::File=HASH(0x497f28)') called at
/Library/Perl/darwin/AxKit.pm line 247
AxKit::handler('AxKit::Apache=SCALAR(0x499518)') called at
/dev/null line 0
eval {...} called at /dev/null line 0
--
www.simonwoodside.com -- 99% Devil, 1% Angel
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]