Page 1 of 1

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

Posted: Sun Jun 12, 2016 11:32 pm
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>

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

Posted: Tue Jun 14, 2016 11:51 am
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

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

Posted: Fri Apr 07, 2017 2:55 pm
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