Error message "Value of {cdata-section-elements} must be a list of QNames in '{uri}local' notation" when using Saxon 9

Having trouble installing Oxygen? Got a bug to report? Post it all here.
Martin Honnen
Posts: 97
Joined: Tue Aug 19, 2014 12:04 pm

Error message "Value of {cdata-section-elements} must be a list of QNames in '{uri}local' notation" when using Saxon 9

Post by Martin Honnen »

When trying to run Saxon 9.6.0.7 HE with oXygen 18 against a stylesheet having

Code: Select all

	<xsl:output cdata-section-elements="MASTER_COMMENTS"/>
I get an error saying

Code: Select all

Description: Value of {cdata-section-elements} must be a list of QNames in '{uri}local' notation
I can't reproduce that problem using the same Saxon version with Java from the command line.

Here is the complete reduced test case:

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0">

<xsl:output cdata-section-elements="MASTER_COMMENTS"/>

<xsl:template match="@* | node()">
<xsl:copy>
<xsl:apply-templates select="@* | node()"/>
</xsl:copy>
</xsl:template>
</xsl:stylesheet>
A sample input document is

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<MASTER_COMMENTS>
<![CDATA[<pre> Nice Work done </pre>]]>
</MASTER_COMMENTS>
alex_jitianu
Posts: 1009
Joined: Wed Nov 16, 2005 11:11 am

Re: Error message "Value of {cdata-section-elements} must be a list of QNames in '{uri}local' notation" when using Saxon

Post by alex_jitianu »

Hello Martin,

Thank you for reporting this issue. I believe I've found the cause and it resides somewhere in Saxon's code. What happens is that Saxon parses the @cdata-section-elements as clark names obtaining: {}MASTER_COMMENTS. Later on, it does a validation of these clark notations and throws that exception. This validation is not performed when running Saxon from the command line and that's why you get the different behavior.

Unfortunately I haven't found a workaround so I've registered an issue and I'll let you know as soon as it gets fixed. We will probably contact Saxonica and ask for there advice on how to correctly address this problem.

Best regards,
Alex
sorin_carbunaru
Posts: 402
Joined: Mon May 09, 2016 9:37 am

Re: Error message "Value of {cdata-section-elements} must be a list of QNames in '{uri}local' notation" when using Saxon

Post by sorin_carbunaru »

Hello Martin,

I wanted to let you know that the newly released oXygen 19.0 comes with Saxon 9.7.0.15, and the problem you reported has been solved.

Best wishes,
Sorin Carbunaru
oXygen XML
Post Reply