itplr-kosit / validator-configuration-xrechnung

Configuration for validating documents against the German XRechnung standard using the KoSIT validation tool
https://xeinkauf.de/xrechnung/
Apache License 2.0
59 stars 16 forks source link

Error because of normalize-space getting multiple arguments #86

Closed VoidTenshi closed 2 weeks ago

VoidTenshi commented 11 months ago

I'm getting the following error when validating an xinvoice:

Error processing schematron validation Schematron rules for EN16931 (CII). Error is A sequence of more than one item is not allowed as the first argument of fn:normalize-space() ("IB", "HS")

It appears when there are multiple "DesignatedProductClassification" elements, like this:

image

Which seems to be allowed by the documentation:

image

The error propably accurs because the validator checks this: normalize-space(ram:SpecifiedTradeProduct/ram:DesignatedProductClassification/ram:ClassCode/@listID)

bdewein commented 10 months ago

This shouldn't be an issue with CEN Schematron 1.3.11 / validator-configuration-xrechnung 2023-11-15, which fixed a bug in BR-65. Should the error still occur, though, it would be helpful if you could add an anonymised example file and validation report.