Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SaxonApiException #434

Closed
cristianvasquez opened this issue Jun 24, 2024 · 3 comments
Closed

SaxonApiException #434

cristianvasquez opened this issue Jun 24, 2024 · 3 comments

Comments

@cristianvasquez
Copy link

@Dragos0000 suggested to report in the corresponding mapping repository.

We are trying to transform some notices for a given day using https://github.com/OP-TED/ted-rdf-conversion-pipeline .

Some of them are failing with this the following error:

image

net.sf.saxon.s9api.SaxonApiException: A sequence of more than one item is not allowed as the first argument of fn:path() (<cac:ProcurementProjectLot>, <cac:ProcurementProjectLot>) at net.sf.saxon.s9api.XPathSelector.evaluate(XPathSelector.java:233) at net.sf.saxon.s9api.XPathCompiler.evaluate(XPathCompiler.java:610) at be.ugent.rml.records.XMLRecord.get(XMLRecord.java:37) at be.ugent.rml.extractor.ReferenceExtractor.extract(ReferenceExtractor.java:31) at be.ugent.rml.extractor.ReferenceExtractor.execute(ReferenceExtractor.java:41) at be.ugent.rml.functions.StaticMultipleRecordsFunctionExecutor.execute(StaticMultipleRecordsFunctionExecutor.java:30) at be.ugent.rml.Executor.getIRIsWithTrueCondition(Executor.java:309) at be.ugent.rml.Executor.getIRIsWithConditions(Executor.java:273) at be.ugent.rml.Executor.generatePredicateObjectGraphs(Executor.java:227) at be.ugent.rml.Executor.executeWithFunction(Executor.java:165) at be.ugent.rml.Executor.execute(Executor.java:123) at be.ugent.rml.cli.Main.run(Main.java:412) at be.ugent.rml.cli.Main.main(Main.java:46) Caused by: net.sf.saxon.trans.XPathException: A sequence of more than one item is not allowed as the first argument of fn:path() (<cac:ProcurementProjectLot>, <cac:ProcurementProjectLot>) at net.sf.saxon.expr.Expression.typeError(Expression.java:1477) at net.sf.saxon.expr.CardinalityChecker.evaluateItem(CardinalityChecker.java:296) at net.sf.saxon.expr.parser.Evaluator$OptionalItem.evaluate(Evaluator.java:201) at net.sf.saxon.expr.SystemFunctionCall.evaluateArguments(SystemFunctionCall.java:469) at net.sf.saxon.expr.FunctionCall.iterate(FunctionCall.java:560) at net.sf.saxon.sxpath.XPathExpression.iterate(XPathExpression.java:176) at net.sf.saxon.s9api.XPathSelector.evaluate(XPathSelector.java:229) ... 12 more net.sf.saxon.s9api.SaxonApiException: A sequence of more than one item is not allowed as the first argument of fn:path() (<cac:ProcurementProjectLot>, <cac:ProcurementProjectLot>) at net.sf.saxon.s9api.XPathSelector.evaluate(XPathSelector.java:233) at net.sf.saxon.s9api.XPathCompiler.evaluate(XPathCompiler.java:610) at be.ugent.rml.records.XMLRecord.get(XMLRecord.java:37) at be.ugent.rml.extractor.ReferenceExtractor.extract(ReferenceExtractor.java:31) at be.ugent.rml.extractor.ReferenceExtractor.execute(ReferenceExtractor.java:41) at be.ugent.rml.functions.StaticMultipleRecordsFunctionExecutor.execute(StaticMultipleRecordsFunctionExecutor.java:30) at be.ugent.rml.Executor.getIRIsWithTrueCondition(Executor.java:309) at be.ugent.rml.Executor.getIRIsWithConditions(Executor.java:273) at be.ugent.rml.Executor.generatePredicateObjectGraphs(Executor.java:227) at be.ugent.rml.Executor.executeWithFunction(Executor.java:165) at be.ugent.rml.Executor.execute(Executor.java:123) at be.ugent.rml.cli.Main.run(Main.java:412) at be.ugent.rml.cli.Main.main(Main.java:46) Caused by: net.sf.saxon.trans.XPathException: A sequence of more than one item is not allowed as the first argument of fn:path() (<cac:ProcurementProjectLot>, <cac:ProcurementProjectLot>) at net.sf.saxon.expr.Expression.typeError(Expression.java:1477) at net.sf.saxon.expr.CardinalityChecker.evaluateItem(CardinalityChecker.java:296) at net.sf.saxon.expr.parser.Evaluator$OptionalItem.evaluate(Evaluator.java:201) at net.sf.saxon.expr.SystemFunctionCall.evaluateArguments(SystemFunctionCall.java:469) at net.sf.saxon.expr.FunctionCall.iterate(FunctionCall.java:560) at net.sf.saxon.sxpath.XPathExpression.iterate(XPathExpression.java:176) at net.sf.saxon.s9api.XPathSelector.evaluate(XPathSelector.java:229) ... 12 more net.sf.saxon.s9api.SaxonApiException: A sequence of more than one item is not allowed as the first argument of fn:path() (<cac:ProcurementProjectLot>, <cac:ProcurementProjectLot>) at net.sf.saxon.s9api.XPathSelector.evaluate(XPathSelector.java:233) at net.sf.saxon.s9api.XPathCompiler.evaluate(XPathCompiler.java:610) at be.ugent.rml.records.XMLRecord.get(XMLRecord.java:37) at be.ugent.rml.extractor.ReferenceExtractor.extract(ReferenceExtractor.java:31) at be.ugent.rml.extractor.ReferenceExtractor.execute(ReferenceExtractor.java:41) at be.ugent.rml.functions.StaticMultipleRecordsFunctionExecutor.execute(StaticMultipleRecordsFunctionExecutor.java:30) at be.ugent.rml.Executor.getIRIsWithTrueCondition(Executor.java:309) at be.ugent.rml.Executor.getIRIsWithConditions(Executor.java:273) at be.ugent.rml.Executor.generatePredicateObjectGraphs(Executor.java:227) at be.ugent.rml.Executor.executeWithFunction(Executor.java:165) at be.ugent.rml.Executor.execute(Executor.java:123) at be.ugent.rml.cli.Main.run(Main.java:412) at be.ugent.rml.cli.Main.main(Main.java:46) Caused by: net.sf.saxon.trans.XPathException: A sequence of more than one item is not allowed as the first argument of fn:path() (<cac:ProcurementProjectLot>, <cac:ProcurementProjectLot>) at net.sf.saxon.expr.Expression.typeError(Expression.java:1477) at net.sf.saxon.expr.CardinalityChecker.evaluateItem(CardinalityChecker.java:296) at net.sf.saxon.expr.parser.Evaluator$OptionalItem.evaluate(Evaluator.java:201) at net.sf.saxon.expr.SystemFunctionCall.evaluateArguments(SystemFunctionCall.java:469) at net.sf.saxon.expr.FunctionCall.iterate(FunctionCall.java:560) at net.sf.saxon.sxpath.XPathExpression.iterate(XPathExpression.java:176) at net.sf.saxon.s9api.XPathSelector.evaluate(XPathSelector.java:229) ... 12 more net.sf.saxon.s9api.SaxonApiException: A sequence of more than one item is not allowed as the first argument of fn:path() (<cac:ProcurementProjectLot>, <cac:ProcurementProjectLot>) at net.sf.saxon.s9api.XPathSelector.evaluate(XPathSelector.java:233) at net.sf.saxon.s9api.XPathCompiler.evaluate(XPathCompiler.java:610) at be.ugent.rml.records.XMLRecord.get(XMLRecord.java:37) at be.ugent.rml.extractor.ReferenceExtractor.extract(ReferenceExtractor.java:31) at be.ugent.rml.extractor.ReferenceExtractor.execute(ReferenceExtractor.java:41) at be.ugent.rml.functions.StaticMultipleRecordsFunctionExecutor.execute(StaticMultipleRecordsFunctionExecutor.java:30) at be.ugent.rml.Executor.getIRIsWithTrueCondition(Executor.java:309) at be.ugent.rml.Executor.getIRIsWithConditions(Executor.java:273) at be.ugent.rml.Executor.generatePredicateObjectGraphs(Executor.java:227) at be.ugent.rml.Executor.executeWithFunction(Executor.java:165) at be.ugent.rml.Executor.execute(Executor.java:123) at be.ugent.rml.cli.Main.run(Main.java:412) at be.ugent.rml.cli.Main.main(Main.java:46) Caused by: net.sf.saxon.trans.XPathException: A sequence of more than one item is not allowed as the first argument of fn:path() (<cac:ProcurementProjectLot>, <cac:ProcurementProjectLot>) at net.sf.saxon.expr.Expression.typeError(Expression.java:1477) at net.sf.saxon.expr.CardinalityChecker.evaluateItem(CardinalityChecker.java:296) at net.sf.saxon.expr.parser.Evaluator$OptionalItem.evaluate(Evaluator.java:201) at net.sf.saxon.expr.SystemFunctionCall.evaluateArguments(SystemFunctionCall.java:469) at net.sf.saxon.expr.FunctionCall.iterate(FunctionCall.java:560) at net.sf.saxon.sxpath.XPathExpression.iterate(XPathExpression.java:176) at net.sf.saxon.s9api.XPathSelector.evaluate(XPathSelector.java:229) ... 12 more 
@schivmeister
Copy link

Thanks for reporting. Unfortunately, we are unable to reproduce this issue on our end, as the transformation works with the following setup:

@cristianvasquez Note that this appears to be an eForms notice and specifically a pipeline issue, so this ticket should be moved to the appropriate project.

@Dragos0000 Please ensure the pipeline environment conforms to the above setup.

Note that RMLMapper v6.2.2 comes bundled with Saxon-HE v11.4:

        <!-- Saxon Home Edition XML, XPath and XQuery parser API -->
        <dependency>
            <groupId>net.sf.saxon</groupId>
            <artifactId>Saxon-HE</artifactId>
            <version>11.4</version>
        </dependency>

@costezki
Copy link
Collaborator

costezki commented Jul 1, 2024

Atfer coordinating with colleagues, it appears that this issue is due to misuse of the pipeline. The operators have loaded incomplete mapping suite which were explicitly marked as alpha tags, which are not supposed to be used.

This issue is related to OP-TED/ted-rdf-mapping-eforms#28

@costezki costezki closed this as completed Jul 1, 2024
@cristianvasquez
Copy link
Author

Related issue: OP-TED/ted-rdf-mapping-eforms#27

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants