FHIR Chat · use of extensions from core · shorthand

Stream: shorthand

Topic: use of extensions from core


view this post on Zulip John Moehrke (Mar 31 2020 at 17:30):

I am getting going again with my sushi build, now that the IG builder supports it... but I now get an error of sorts. I presume I am not using an extension right... but am not sure.

Sushi has failed - no errors count in the output. Complete output from running Sushi : warn Extension with slice name 'workflow-reasonCode' will be treated as an inline extension, even though the name can be resolved to the external extension: http://hl7.org/fhir/StructureDefinition/workflow-reasonCode. Starting with SUSHI 0.10.0, extension (00:04.0521)

see https://github.com/JohnMoehrke/MHD-fsh

view this post on Zulip Chris Moesel (Mar 31 2020 at 17:38):

I believe that the following message is a red herring:

Sushi has failed - no errors count in the output.

See: https://chat.fhir.org/#narrow/stream/179252-IG-creation/topic/Sushi.20Support/near/192082552

view this post on Zulip Chris Moesel (Mar 31 2020 at 17:40):

As for the warning, see the SUSHI 0.10.0 release notes about the breaking change to the extension syntax: https://github.com/FHIR/sushi/releases/tag/v0.10.0

I don't know if the IG Publisher shows you the full warning message, but if it does, then the message should include the suggested FSH syntax if you do intend to refer to the existing workflow-reasonCode extension.

view this post on Zulip John Moehrke (Mar 31 2020 at 17:58):

nothing more shown from sushi. I will try running sushi directly

view this post on Zulip John Moehrke (Mar 31 2020 at 18:03):

sushi directly does give far more rich information. They are just warnings, so I would expect the IG build would have continued, but didn't.

view this post on Zulip John Moehrke (Mar 31 2020 at 18:47):

I am not getting the Alias to work...

Parent: List
Id: IHE.MHD.Minimal.ListManifest
Title: "MHD SubmissionSet in List"
Description: "A profile on the List resource for MHD SubmissionSet."
Alias: ReasonCodeExtension = http://hl7.org/fhir/StructureDefinition/workflow-reasonCode

  • ^version = "3.1.1"
  • ^date = "2020-02-01"

view this post on Zulip John Moehrke (Mar 31 2020 at 18:48):

im trying to follow http://build.fhir.org/ig/HL7/fhir-shorthand/reference.html#extension-rules

view this post on Zulip John Moehrke (Mar 31 2020 at 18:59):

I get sushi error

error extraneous input '*' expecting {<EOF>, KW_ALIAS, KW_PROFILE, KW_EXTENSION, KW_INSTANCE, KW_INVARIANT, KW_VALUESET, KW_CODESYSTEM}
File: C:\Users\john.moehrke\Git\MHD-fsh\fsh\submissionSet.fsh
Line: 8
i

view this post on Zulip Jose Costa Teixeira (Mar 31 2020 at 19:09):

can you paste your file here, up to line 8 at least?

view this post on Zulip Jose Costa Teixeira (Mar 31 2020 at 19:10):

submissionSet.fsh

view this post on Zulip John Moehrke (Mar 31 2020 at 20:00):

https://github.com/JohnMoehrke/MHD-fsh

view this post on Zulip Jose Costa Teixeira (Mar 31 2020 at 20:33):

not sure if that is also the problem on your end but yesterday i had an issue due to white space. And in your line 7 you have some funn characters in line 7, between Alias: and ReasonCodeExtension.

view this post on Zulip Jose Costa Teixeira (Mar 31 2020 at 20:34):

so i'd try to replace whatever is there by plain white space

view this post on Zulip Chris Moesel (Mar 31 2020 at 21:12):

@John Moehrke -- Aliases are standalone entities and are global in scope (within your project). You're getting that error because you put an Alias right in the middle of a Profile definition. You can fix it by moving the Alias: ... line out of the profile definition.

view this post on Zulip Chris Moesel (Mar 31 2020 at 21:14):

I usually put aliases at the top of the file, although that is not required. Some projects actually create a separate file just for their aliases (since they are global in scope). This especially makes sense for aliases you will use in multiple places throughout your project. For an example of the latter approach, see this file in mCODE: https://github.com/HL7/fhir-mCODE-ig/blob/master/fsh/USCoreAliases.fsh

view this post on Zulip Jose Costa Teixeira (Apr 01 2020 at 10:40):

@Nicolas Duvivier fyi


Last updated: Apr 12 2022 at 19:14 UTC