Stream: shorthand
Topic: Error Referencing a Extension using Link
saran (Nov 30 2021 at 18:34):
Hi, I'm trying to reference an extension of US-Core through an alias link as defined below, but end up getting an error.
Please find the details below:
Alias: $us-core-race = http://hl7.org/fhir/us/core/StructureDefinition/us-core-race
Alias: $us-core-ethnicity = http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity
Alias: $us-core-birthsex = http://hl7.org/fhir/us/core/StructureDefinition/us-core-birthsex
Alias: $us-core-usps-state = http://hl7.org/fhir/us/core/ValueSet/us-core-usps-state
extension contains
$us-core-race named race 0..1 and
$us-core-ethnicity named ethnicity 0..1 and
$us-core-birthsex named birthsex 0..1
When I try to run it in SUSHI it gives me the following error - "Cannot create race extension; unable to locate extension definition for : https://www.hl7.org/fhir/us/core/StructureDefinition-us-core-race."
Can someone please help me with this one? Thank you!
David Pyke (Nov 30 2021 at 18:58):
Have you declared USCore as a dependency of your IG?
saran (Nov 30 2021 at 19:54):
Added the dependency but still same error message
David Pyke (Dec 01 2021 at 17:31):
Can you show us the complete extension definition? (Headers and all)
Chris Moesel (Dec 01 2021 at 18:27):
@saran -- if I don't declare a dependency on US Core, I get those errors. But when I declare a dependency on US Core, it works without error. Here is a FSH Online link w/ US Core dependency in the configuration. You'll see that it runs clean: https://fshschool.org/FSHOnline/#/share/3FWdcOS
In your sushi-config.yaml, you would want:
dependencies:
hl7.fhir.us.core: 4.0.0
saran (Dec 02 2021 at 19:22):
Thanks that helped. I was using different link. Then when i changed the link it worked.
Initial Link : https://www.hl7.org/fhir/us/core/StructureDefinition-us-core-race
Changed Link : http://hl7.org/fhir/us/core/StructureDefinition/us-core-race
Last updated: Apr 12 2022 at 19:14 UTC