When validating our (STU3) profiles, we get a lot of errors with the message: "element [path] launches straight into slicing without the slicing being set up properly first".
It seems that the validator expects the value[x] element to be defined before jumping into the valueString slice. Validation is successful when changing the code to:
But the validator still complains about the element launching straight into slicing:
Error @ StructureDefinition.snapshot.element[18]: The element Consent.extension:additionalAdvanceDirective.value[x]:valueReference launches straight into slicing without the slicing being set up properly first
It seems that the snapshot generator is creating this path from the differential, since this path is no longer present in the differential. Is the snapshot generator doing something here that is not allowed or is the first syntax already correct and should the validator not complain about this? Or are we missing something and did we do something wrong in our own code?
When validating our (STU3) profiles, we get a lot of errors with the message: "element [path] launches straight into slicing without the slicing being set up properly first".
For example, the following code in https://simplifier.net/geboortezorg-stu3/bc-breastfindings produced this error:
It seems that the validator expects the value[x] element to be defined before jumping into the valueString slice. Validation is successful when changing the code to:
We have another example (https://simplifier.net/geboortezorg-stu3/bc-treatmentdirective), however, where the same trick did not result in successful validation: We changed the code from:
To:
But the validator still complains about the element launching straight into slicing:
Error @ StructureDefinition.snapshot.element[18]: The element Consent.extension:additionalAdvanceDirective.value[x]:valueReference launches straight into slicing without the slicing being set up properly first
It seems that the snapshot generator is creating this path from the differential, since this path is no longer present in the differential. Is the snapshot generator doing something here that is not allowed or is the first syntax already correct and should the validator not complain about this? Or are we missing something and did we do something wrong in our own code?