saxon XPTY0019 errors in Oxygen, not on command-line

Oxygen general issues.
Ron Van den Branden
Posts: 65
Joined: Fri Jan 18, 2008 5:54 pm

saxon XPTY0019 errors in Oxygen, not on command-line

Post by Ron Van den Branden »

Hi,

When testing some (fairly complex) stylesheets with Saxon 9, I noticed a vast amount of XPTY0019 errors being output, caused by complex match expressions in the stylesheet. When trying to debug them with Oxygen 9.1, I noticed a discrepancy between Oxygen's XSLT processing and commandline results, both using Saxon 9.0.0.3 (I updated Oxygen's original Saxon 9 libs with the most recent ones).

Following reduction of my problem succeeds on the command-line:

XML:
====
<?xml version="1.0" encoding="UTF-8"?>
<test>
<el att="1"><sub/></el>
<el att="2"></el>
</test>

XSLT:
=====
<?xml version="1.0" encoding="iso-8859-1"?>
<xsl:stylesheet version="2.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<xsl:template match="*[@att='1' or @att='2'][current()/*]">MATCHED: <xsl:copy-of select="."/></xsl:template>

</xsl:stylesheet>

RESULT:
=======
<?xml version="1.0" encoding="UTF-8"?>
MATCHED: <el att="1"><sub/></el>

However, when I try this in Oxygen's XSLT debugger view, I get an empty output with following warning (twice):

Code: Select all


Description: An error occurred matching pattern {*[@att='1' or @att='2'][current()/*]}: 
URL: http://www.w3.org/TR/xpath20/#ERRXPTY0019
This clearly indicates that a) my actual problem is still unsolved (I still need to figure out what parts of the match expression cause the XPTY0019 errors) and b) resolution is hampered by an inconvenient difference between invocation of the same XSLT processor (Saxon 9.0.0.3) on the command line and in Oxygen's XSLT debugging context.

Does anyone have any thoughts on these issues?

Kind regards,

Ron
Dan
Posts: 501
Joined: Mon Feb 03, 2003 10:56 am

Post by Dan »

Hello,

I have executed a transformation using your samples and the result was:

Code: Select all


<?xml version="1.0" encoding="UTF-8"?>
MATCHED: <el att="1"><sub/></el>
without any warnings.

Please make sure you have the latest oXygen build: 2007122116. You can check this using the Help/About dialog. (In this build there are some differences in the Saxon integration.)

Let us know if this was the problem.
Regards,
Dan
Ron Van den Branden
Posts: 65
Joined: Fri Jan 18, 2008 5:54 pm

Post by Ron Van den Branden »

Hi Dan,

Indeed, I can confirm that the problem is fixed in the latest build, this produces the same results as you posted. Sorry for the noise: I wasn't aware that the update facility didn't consider minor builds and thought I was using the most recent version.

Anyway, thanks for the suggestion! Now I can get on chasing the real XPTY0019 errors...

Kind regards,

Ron
Post Reply