cqframework / cqframework/cqf-tooling
ModelInfo for singular elements derived from plural ones
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 22
- Forks
- 26
- PR merge metrics
- No merged PRs in 30d
Description
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):
https://github.com/cqframework/clinical_quality_language/issues/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.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the ModelInfo generation for derived elements whose cardinality changes from plural to singular, using the linked translator issue for the QICore 4.1.1 example. Done means derived elements retain plural cardinality when their underlying classes remain plural, preventing the reported runtime error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100