Bug #4547
closed
Cannot export a package containing abstract components
Category:
XSLT 3.0 packages
Fix Committed on Branch:
10
Fixed in Maintenance Release:
Description
Using the command line:
net.sf.saxon.Transform -xsl:override-base-f-001.xsl -export:override-base-f-001.sef -nogo
fails
Error
XTSE3080 The package is not executable, because it contains abstract components: function
p:f-abstract#2
The error should not occur unless we actually attempt execution.
- Fix Committed on Branch 10 added
A bit tricky to fix this. The command-line with -nogo
option is compiling the stylesheet as if it were to execute, and then simply skips the execution phase; up till then the logic is essentially "compile complete stylesheet" rather than "compile free-standing package". My first instinct was to try and defer the error check (or the reporting of the error) until PreparedStylesheet.newController()
; but that method doesn't throw an exception, and if it did, then XsltExecutable.load()
would have to throw an exception, which is an unpleasant API change.
I've added a special path to the already tortuous Transform.doTransform()
method: if export && !run
(i.e. the -export and -nogo options are set) then it uses compilePackage
rather than compile
, which doesn't require the package to be executable.
Making this change for 10.0 only in the interests of stability.
- Status changed from New to Resolved
- % Done changed from 0 to 100
- Fixed in Maintenance Release 10.1 added
Bug fix committed in the Saxon 10.1 maintenance release.
- Status changed from Resolved to Closed
Please register to edit this issue
Also available in: Atom
PDF