Hi Graeme,
The DocBook XSL stylesheets are written for XSLT 1.0, and Saxon 9 (HE or
EE) is a XSLT 2.0 processor. The 1.0 DocBook stylesheets do not work
reliably with Saxon 9, even with the backwards compatibility mode. All
the XSLT 1.0 processors now support the EXSLT functions, so that
dependency has not generally been a problem. There is a separate effort
to develop DocBook stylesheets for XSLT 2.0, but I don't think it has
stylesheets for assembly yet. Sorry.
--
Bob Stayton
Sagehill Enterprises
[email protected]
On 11/20/2013 9:02 AM, [email protected] wrote:
Sorry folks, one more detail: I also tried the XPL workflow in both
calabash-1.0.15-95 and calabash-1.0.15-94 to see if the issue was caused
by the version of Saxon I'm using.
I read somewhere that Saxon HE doesn't support the EXSLT extension
functions, so I tried to select EE by adding the '-P he' flag. That
didn't make any difference.
Do the DocBook stylesheets really require the EXSLT extension functions?
If so, is there a workaround to be able to use them with Saxon-HE? I
don't have EE and don't have an easy way of obtaining it.
Thanks,
Graeme
On Wed, Nov 20, 2013, at 12:03, [email protected] wrote:
Hi there,
I'm not quite sure whether this is a DocBook question or a
Calabash/XProc one, but given that there's a substantial overlap between
the developers and users of both, hopefully someone will be able to
answer it here.
I'm processing DocBook 5.1 assembly files with the DocBook namespace
stylesheets version 1.78.0. Using Saxon 8.7 and the
'assembly/assemble.xsl' stylesheet, I can turn my assemblies into
'consolidated' DocBook articles, books (or whatever).
However, when I apply the same XSLT transformation using Calabash XProc,
I get the following error:
calabash -D --input
source=file:/Users/graeme/git/ncr/documentation/projects/project.xml
doc-generate.xpl
Nov 20, 2013 11:42:05 AM
com.xmlcalabash.util.DefaultXProcMessageListener error
SEVERE:
file:/Users/graeme/git/ncr/documentation/target/generated-resources/docbook/assembly/assemble.xsl:552:err:XTDE1425:Cannot
find a matching 1-argument function named
{http://exslt.org/common}node-set(). There is no Saxon extension
function with the local name node-set
Nov 20, 2013 11:42:05 AM
com.xmlcalabash.util.DefaultXProcMessageListener error
SEVERE: Cannot find a matching 1-argument function named
{http://exslt.org/common}node-set(). There is no Saxon extension
function with the local name node-set
Nov 20, 2013 11:42:05 AM com.xmlcalabash.drivers.Main error
SEVERE: Pipeline failed: net.sf.saxon.s9api.SaxonApiException: Cannot
find a matching 1-argument function named
{http://exslt.org/common}node-set(). There is no Saxon extension
function with the local name node-set
Nov 20, 2013 11:42:05 AM com.xmlcalabash.drivers.Main error
SEVERE: Underlying exception: net.sf.saxon.trans.XPathException: Cannot
find a matching 1-argument function named
{http://exslt.org/common}node-set(). There is no Saxon extension
function with the local name node-set
net.sf.saxon.s9api.SaxonApiException: Cannot find a matching 1-argument
function named {http://exslt.org/common}node-set(). There is no Saxon
extension function with the local name node-set
at
net.sf.saxon.s9api.XsltTransformer.transform(XsltTransformer.java:433)
at com.xmlcalabash.library.XSLT.run(Unknown Source)
at com.xmlcalabash.runtime.XAtomicStep.run(Unknown Source)
at com.xmlcalabash.runtime.XForEach.run(Unknown Source)
at com.xmlcalabash.runtime.XForEach.run(Unknown Source)
at com.xmlcalabash.runtime.XPipeline.doRun(Unknown Source)
at com.xmlcalabash.runtime.XPipeline.run(Unknown Source)
at com.xmlcalabash.drivers.Main.run(Unknown Source)
at com.xmlcalabash.drivers.Main.main(Unknown Source)
Caused by: net.sf.saxon.trans.XPathException: Cannot find a matching
1-argument function named {http://exslt.org/common}node-set(). There is
no Saxon extension function with the local name node-set
at
net.sf.saxon.expr.ErrorExpression.evaluateItem(ErrorExpression.java:66)
at
net.sf.saxon.expr.ErrorExpression.iterate(ErrorExpression.java:80)
at net.sf.saxon.expr.ItemChecker.iterate(ItemChecker.java:157)
at
net.sf.saxon.expr.SlashExpression.iterate(SlashExpression.java:700)
at
net.sf.saxon.expr.SlashExpression.iterate(SlashExpression.java:700)
at
net.sf.saxon.expr.sort.DocumentSorter.iterate(DocumentSorter.java:101)
at net.sf.saxon.value.MemoClosure.iterate(MemoClosure.java:105)
at net.sf.saxon.value.Value.asIterator(Value.java:127)
at
net.sf.saxon.expr.VariableReference.iterate(VariableReference.java:442)
at
net.sf.saxon.expr.SlashExpression.iterate(SlashExpression.java:700)
at
net.sf.saxon.expr.sort.DocumentSorter.iterate(DocumentSorter.java:101)
at
net.sf.saxon.expr.instruct.ForEach.processLeavingTail(ForEach.java:414)
at
net.sf.saxon.expr.instruct.Block.processLeavingTail(Block.java:615)
at
net.sf.saxon.expr.instruct.Instruction.process(Instruction.java:131)
at
net.sf.saxon.expr.instruct.ElementCreator.processLeavingTail(ElementCreator.java:301)
at
net.sf.saxon.expr.instruct.ElementCreator.processLeavingTail(ElementCreator.java:254)
at
net.sf.saxon.expr.LetExpression.processLeavingTail(LetExpression.java:586)
at
net.sf.saxon.expr.instruct.Choose.processLeavingTail(Choose.java:794)
at
net.sf.saxon.expr.LetExpression.processLeavingTail(LetExpression.java:586)
at
net.sf.saxon.expr.instruct.Block.processLeavingTail(Block.java:615)
at
net.sf.saxon.expr.LetExpression.processLeavingTail(LetExpression.java:586)
at
net.sf.saxon.expr.instruct.Block.processLeavingTail(Block.java:615)
at net.sf.saxon.expr.instruct.Template.expand(Template.java:231)
at
net.sf.saxon.expr.instruct.CallTemplate.process(CallTemplate.java:338)
at
net.sf.saxon.expr.instruct.CallTemplate.processLeavingTail(CallTemplate.java:386)
at
net.sf.saxon.expr.instruct.Block.processLeavingTail(Block.java:615)
at
net.sf.saxon.expr.instruct.Instruction.process(Instruction.java:131)
at
net.sf.saxon.expr.instruct.ElementCreator.processLeavingTail(ElementCreator.java:301)
at
net.sf.saxon.expr.instruct.ElementCreator.processLeavingTail(ElementCreator.java:254)
at
net.sf.saxon.expr.instruct.Choose.processLeavingTail(Choose.java:794)
at
net.sf.saxon.expr.LetExpression.processLeavingTail(LetExpression.java:586)
at
net.sf.saxon.expr.instruct.Block.processLeavingTail(Block.java:615)
at
net.sf.saxon.expr.LetExpression.processLeavingTail(LetExpression.java:586)
at
net.sf.saxon.expr.instruct.Choose.processLeavingTail(Choose.java:794)
at
net.sf.saxon.expr.LetExpression.processLeavingTail(LetExpression.java:586)
at
net.sf.saxon.expr.instruct.Block.processLeavingTail(Block.java:615)
at
net.sf.saxon.expr.LetExpression.processLeavingTail(LetExpression.java:586)
at
net.sf.saxon.expr.instruct.Block.processLeavingTail(Block.java:615)
at
net.sf.saxon.expr.instruct.Template.applyLeavingTail(Template.java:212)
at net.sf.saxon.trans.Mode.applyTemplates(Mode.java:1032)
at
net.sf.saxon.expr.instruct.ApplyTemplates.apply(ApplyTemplates.java:237)
at
net.sf.saxon.expr.instruct.ApplyTemplates.processLeavingTail(ApplyTemplates.java:199)
at
net.sf.saxon.expr.instruct.Block.processLeavingTail(Block.java:615)
at
net.sf.saxon.expr.instruct.Instruction.process(Instruction.java:131)
at
net.sf.saxon.expr.instruct.ElementCreator.processLeavingTail(ElementCreator.java:301)
at
net.sf.saxon.expr.instruct.ElementCreator.processLeavingTail(ElementCreator.java:254)
at
net.sf.saxon.expr.LetExpression.processLeavingTail(LetExpression.java:586)
at
net.sf.saxon.expr.instruct.Template.applyLeavingTail(Template.java:212)
at net.sf.saxon.trans.Mode.applyTemplates(Mode.java:1032)
at
net.sf.saxon.trans.TextOnlyCopyRuleSet.process(TextOnlyCopyRuleSet.java:58)
at net.sf.saxon.trans.Mode.applyTemplates(Mode.java:1020)
at
net.sf.saxon.trans.TextOnlyCopyRuleSet.process(TextOnlyCopyRuleSet.java:58)
at net.sf.saxon.trans.Mode.applyTemplates(Mode.java:1020)
at
net.sf.saxon.Controller.transformDocument(Controller.java:1957)
at net.sf.saxon.Controller.transform(Controller.java:1803)
at
net.sf.saxon.s9api.XsltTransformer.transform(XsltTransformer.java:430)
... 8 more
Here's the XSLT step in question from my XProc script:
<p:xslt name="assemble-docbook">
<p:input port="stylesheet">
<p:document
href="../target/generated-resources/docbook/assembly/assemble.xsl"/>
</p:input>
<p:input port="parameters">
<p:empty/>
</p:input>
</p:xslt>
The input to this step (the 'source' port) is a DocBook assembly
document, with all the necessary 'resource' elements defined, and a
single 'structure' element which references them. The 'stylesheet' port
references the DocBook 1.78.0 assemble.xsl stylesheet.
I'm using the following Calabash version:
XML Calabash version 1.0.3 (for Saxon 9.4.x), an XProc processor.
Running on Saxon version 9.4.0.2, HE edition.
I'd appreciate any guidance on what might be going wrong.
Thanks,
Graeme
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]