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

ModelInfo for singular elements derived from plural ones #427

Open
brynrhodes opened this issue Mar 28, 2023 · 1 comment
Open

ModelInfo for singular elements derived from plural ones #427

brynrhodes opened this issue Mar 28, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@brynrhodes
Copy link
Member

When a profile changes cardinality of a plural element to singular, the ModelInfo outputs the element in the profile as a singular element, rather than as a List of elements. This results in run-time errors because the underlying classes still have the plural modeling based on the ancestor profile and ultimately resource definition.

The issue was reported on the translator here (for QICore 4.1.1):
cqframework/clinical_quality_language#1136

The issue was addressed there by manually updating the MedicationNotRequested.reasonCode element to be plural, but the tooling in general should not reduce cardinality of derived elements to avoid this runtime issue.

@brynrhodes brynrhodes added the bug Something isn't working label Mar 28, 2023
@ddieppois
Copy link
Contributor

Same issue as #428 as I'm facing this error when trying to build the ModelInfo. This seems to be due to an now outdated library that we rely on.

java.lang.LinkageError: loader constraint violation: when resolving field "DATETIME" of type javax.xml.namespace.QName, the class loader org.codehaus.mojo.exec.URLClassLoaderBuilder$ExecJavaClassLoader @6ddee60f of the current class, org.glassfish.jaxb.runtime.v2.model.impl.RuntimeBuiltinLeafInfoImpl, and the class loader 'bootstrap' for the field's defining type, javax.xml.datatype.DatatypeConstants, have different Class objects for type javax.xml.namespace.QName (org.glassfish.jaxb.runtime.v2.model.impl.RuntimeBuiltinLeafInfoImpl is in unnamed module of loader org.codehaus.mojo.exec.URLClassLoaderBuilder$ExecJavaClassLoader @6ddee60f, parent loader 'app'; javax.xml.datatype.DatatypeConstants is in module java.xml of loader 'bootstrap')

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants