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

Conflicting Aliases are not reported #124

Closed
cmoesel opened this issue Jan 22, 2020 · 1 comment
Closed

Conflicting Aliases are not reported #124

cmoesel opened this issue Jan 22, 2020 · 1 comment
Assignees
Labels
bug Something isn't working released Available in an official SUSHI release

Comments

@cmoesel
Copy link
Member

cmoesel commented Jan 22, 2020

If an author defines the same Alias with two different values, only one of them will be used -- but there is no error indicating what happened. We should log an error when we encounter a duplicate Alias definition with a different value than the previous one.

This came up in fsh-mcode. In CodeSystemAliases.fsh, it had:

Alias:   USCoreRace = http://hl7.org/fhir/us/core/ValueSet/omb-race-category

But in USCoreAliases and Examples.fsh, it had:

Alias:   USCoreRace = http://hl7.org/fhir/us/core/StructureDefinition/us-core-race

I noticed this when reviewing this line in Examples.fsh, where the same alias is used twice: once to replace an Extension URL and once to replace a VS URL:

* extension[USCoreRace].extension[ombCategory].valueCoding = USCoreRace#2186-5 "Not Hispanic or Latino"
@cmoesel cmoesel added the bug Something isn't working label Jan 22, 2020
@cmoesel cmoesel self-assigned this Jan 22, 2020
cmoesel added a commit that referenced this issue Jan 22, 2020
If a FSHTank contains duplicate aliases with different values, only keep the first one and report the others as errors.  Addresses #124.
kjmahalingam pushed a commit that referenced this issue Jan 22, 2020
* Report duplicate aliases w/ different values

If a FSHTank contains duplicate aliases with different values, only keep the first one and report the others as errors.  Addresses #124.

* Fix test name
@cmoesel cmoesel added the merged label Jan 22, 2020
@cmoesel
Copy link
Member Author

cmoesel commented Jan 22, 2020

Fixed in 0.6.1

@cmoesel cmoesel closed this as completed Jan 22, 2020
@cmoesel cmoesel added the released Available in an official SUSHI release label Jan 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working released Available in an official SUSHI release
Projects
None yet
Development

No branches or pull requests

1 participant