Stream: shorthand
Topic: R5 support
Catherine Hosage Norman (Aug 10 2021 at 16:13):
This line: * SubstanceDefinition.name.name 0..* MS
gets this error
info Converting FSH to FHIR resources...
error No element found at path SubstanceDefinition.name.name for DrugSubstance, skipping rule
It is odd that the error message says DrugSubstance and not SubstanceDefinition
Nick Freiter (Aug 10 2021 at 17:52):
I believe this is because DrugSubstance
is the name of the Profile
where this error is occurring. For example, I can recreate this with the following definition:
Nick Freiter (Aug 10 2021 at 17:52):
Profile: DrugSubstance
Parent: SubstanceDefinition
* SubstanceDefinition.name.name 0..* MS
Nick Freiter (Aug 10 2021 at 17:53):
In this case, I think the solution would be to not include SubstanceDefinition
in the rule. So try something like
name.name 0..* MS
Brian Alper (Nov 16 2021 at 15:54):
We are hoping to use FSH and SUSHI to create a new IG with a Profile of a Resource about to be added to the CI-build version of FHIR R5. The CI-build version of FHIR R5 does not have a numbered version, and the most recent numbered version (4.6.0 which is the R5 ballot snapshot from half a year ago) is not current enough for our IG.
Is there a way to use FSH and SUSHI with the current-build R5, or is there a way to insert the Resource StructureDefinition (that we know and can isolate) so we can use FSH to develop a Profile of this Resource? @Alex Goel
Jean Duteau (Nov 16 2021 at 15:55):
considering that the IG Publisher doesn't go against #current, I'm not sure how much support SUSHI should give to it. Basically SUSHI only supports what the IG Publisher supports so it's up to Grahame and team to add support for #current.
Gino Canessa (Nov 16 2021 at 16:04):
On your local computer, you can update your cached version of FHIR (~/.fhir/packages
) and use that. It will let you build locally, since IG Publisher looks there first. (There are more detailed instructions either on this stream or in #IG creation - though it was probably documented against R4B instead of R5).
To my knowledge, there is not a way to get the CI builds of that process working yet.
Chris Moesel (Nov 16 2021 at 16:37):
So... SUSHI does support fhirVersion: current
in the sushi-config.yaml
-- and will download and use the latest CI build of FHIR for that. SUSHI stores the CI build of FHIR R5 in the FHIR cache at ~/.fhir/packages/hl7.fhir.r5.core#current
.
That said, as @Jean Duteau noted above, the IG Publisher does not support building IGs against FHIR R5 current -- so even though SUSHI supports it, you won't get too far with it after that.
As for ways to work around this (by including the JSON resource in the IG, etc.) -- I'm not sure, but it may be possible. I'll do a little testing with it.
Gino Canessa (Nov 16 2021 at 16:45):
To clarify; if you do the process Chris describes, you will have the hl7.fhir.r5.core#current
directory in your cache. If you rename that to hl7.fhir.r5.core#4.6.0
(and do the same for hl7.fhir.r5.expansions#current
with hl7.fhir.r5.expansions#4.6.0
), you can then build against 4.6.0
, which works in both sushi and IG Publisher.
Again note that this only works locally since you are manually replacing the files (e.g., the CI build of your IG will fail). I have been taking the output folder and posting the contents in a github.io
repo to make them publicly available.
Chris Moesel (Nov 16 2021 at 16:53):
@Brian Alper -- I gave your idea a shot and had some surprising luck with it. Here's what I did:
- Set
fhirVersion: 4.6.0
insushi-config.yaml
(since it is the most recent FHIR R5 the IG Publisher supports) - Added StructureDefinition-DeviceDispense.json to
input/resources
in my IG project (an example of a resource in current build but not 4.6.0) - Added the following in
sushi-config.yaml
to tell SUSHI not to include DeviceDispense in the ImplementationGuide JSON
resources:
StructureDefinition/DeviceDispense: omit
- Created a FSH profile w/
Parent: DeviceDispense
The above worked fine in SUSHI, and more surprisingly, seemed to work in the IG Publisher. There were some errors in the QA, but the IG Publisher did not crash and produced a fairly useful IG w/ my profile in it. I'd still label this as "very experimental", but it may get you what you need for now.
Brian Alper (Nov 16 2021 at 17:11):
@Alex Goel @Bryn Rhodes @Khalid Shahin @Chris Moesel Thanks, Chris. Perhaps we can create an EBMonFHIR IG with a Recommendation Profile (of ArtifactAssessment Resource about to be added to FHIR current build) and see it work in the IG Publisher. If we keep the test limited this will essentially involve 1 Profile, 2 value sets, 1 code system (if the value sets can be subsets of values from the code system), and 1 IG.
Jens Villadsen (Dec 13 2021 at 11:21):
I need a word of advise here. Whats the latest stable version (R5-wise) that works across fsh and the IG builder using the CI/CD chain? What version should I state in the sushi-config?
Jens Villadsen (Dec 13 2021 at 11:24):
Currently using 4.6.0
does not seem to work. The CI/CD on (https://github.com/hl7-eu/gravitate-health/tree/fixing) is not happy about the current situation (https://build.fhir.org/ig/hl7-eu/gravitate-health/branches/fixing/failure/build.log)
Jens Villadsen (Dec 13 2021 at 14:09):
It looks like sushi does not care whether eg. the instance properties are arrays or not. As can be see on https://build.fhir.org/ig/hl7-eu/gravitate-health/branches/fixing/failure/fsh-generated/resources/RegulatedAuthorization-cfsb1639234802176.json - where the fsh-generated files gives you a single property, the IG expects an array as can be see on http://build.fhir.org/regulatedauthorization.html - @Chris Moesel any advise is highly appreciated
Jens Villadsen (Dec 13 2021 at 14:33):
(@Craig Anderson )
Chris Moesel (Dec 13 2021 at 14:42):
SUSHI does care whether instances are arrays or not -- and outputs them accordingly. You identified your FHIR version as 4.6.0. SUSHI used the official 4.6.0 (May 2021 ballot) release , in which RegulatedAuthorization.subject is 0..1. The IG Publisher, however, appears to be using the current build (including changes since the 4.6.0 release), in which RegulatedAuthorization.subject is 0..*.
In my opinion, SUSHI is doing the right thing here by using the actual 4.6.0 release that is available in the package registry. But I am biased. @Grahame Grieve -- does the IG Publisher intentionally use current build when the IG calls for 4.6.0?
Grahame Grieve (Dec 13 2021 at 18:29):
running against R5 current is not supported at this time. And in practice, running against the 4.6.0 isn't either. It's on my list of things to do once I publish the next milestone of R5 in the next week
Jens Villadsen (Dec 13 2021 at 18:55):
@Chris Moesel you're right - it does indeed care - wrong wording from my side.
Jens Villadsen (Dec 13 2021 at 18:57):
So if 4.6.0 is the May Release - then what does the IG publisher think 4.6.0
is - because it seems like the IG publisher thinks it is something different. @Grahame Grieve I'm not targeting current
then I assume. I target 4.6.0
. Ain't that supported by the publisher?
Jens Villadsen (Dec 13 2021 at 18:58):
I'm confused here :oh_no:
Jens Villadsen (Dec 13 2021 at 19:08):
OK - I guess I'll have to wait for next week then.
Grahame Grieve (Dec 13 2021 at 19:10):
I'm afraid so
Jens Villadsen (Dec 13 2021 at 19:58):
So its gonna be christmas after all :D
Jens Villadsen (Dec 13 2021 at 19:58):
FYI - our connectathon track sort of heavily depends on it
Grahame Grieve (Dec 13 2021 at 19:59):
so, no pressure...
Jens Villadsen (Dec 13 2021 at 20:00):
You said it ... :rolling_on_the_floor_laughing:
Jens Villadsen (Dec 13 2021 at 20:01):
Craig Anderson (Dec 13 2021 at 20:43):
@Jens Villadsen, does this mean the FSH ePI content is compliant? Or do we have to wait until Grahame finishes his component to confirm?
Jens Villadsen (Dec 13 2021 at 20:44):
@Craig Anderson Easiest is to wait
Chris Moesel (Dec 13 2021 at 21:09):
So... this is super hacky, but I'll throw it out there. Here is the current situation:
- fhirVersion: 4.6.0:
- SUSHI: Uses the 4.6.0 package from the registry (May 2021 R5 ballot)
- IG Publisher: I think it uses the current R5 build (and it sort of works?)
- fhirVersion: current:
- SUSHI: Uses the current R5 build
- IG Publisher: Does not work
Based on this, if you actually want current
, I think you could set fhirVersion: current
in sushi-config.yaml and run SUSHI that way. THEN modify the ImplementationGuide JSON file in fsh-generated to change fhirVersion
to [ "4.6.0" ]
-- since IG Publisher currently treats that like current. Then run IG Publisher with the -no-sushi
flag (so it doesn't re-run SUSHI and overwrite your modifications in fsh-generated).
Again, it's a hack. So use at your own peril!
Chris Moesel (Dec 13 2021 at 21:10):
(And it will / should break whenever Grahame addresses this in IG Publisher).
Jens Villadsen (Dec 13 2021 at 22:42):
Naaa .... doing sushi . ; sed -i '' -e 's/current/4.6.0/g' fsh-generated/resources/ImplementationGuide-hl7.eu.fhir.gh.json && ./_genonce.sh -no-sushi
didn't do it @Chris Moesel
Chris Moesel (Dec 13 2021 at 23:52):
Dang. Sorry. I thought that might work. I guess you'll just have to wait. :-/
Jens Villadsen (Dec 13 2021 at 23:53):
np - I'm waiting ...
Jens Villadsen (Dec 13 2021 at 23:53):
It was worth a shot
Chris Moesel (Dec 14 2021 at 00:29):
I just tried it as well. I'm not sure where you stopped, but when I did it, the real problem was when I changed fhirVersion
to current
in the SUSHI project. After that, SUSHI reported 151 errors because so many other things have changed since the 4.6.0 R5 ballot release. To fully test out my hack, I'd need to go in and fix all those 151 errors in the FSH to align w/ the changes in FHIR R5 current.
Chris Moesel (Dec 14 2021 at 00:33):
Things like:
error Cannot assign Reference value: Reference(Organization/cfsb1639015344307). Value does not match element type: BackboneElement
because Ingredient.manufacturer
changed from a Reference in 4.6.0 to a BackboneElement in current build.
Jens Villadsen (Dec 14 2021 at 15:46):
Maybe it was a bit late when I gave up .... :sleeping:
Jens Villadsen (Dec 15 2021 at 19:50):
@Chris Moesel you're right. Flipping the version to current certainly triggered something. @Craig Anderson are you able to run sushi locally?
Chris Moesel (Dec 15 2021 at 21:24):
Yeah, and that's expected. There are a lot of differences between the May 2021 4.6.0 ballot build and current. The question is, which one are you trying to target? The 4.6.0 ballot package or latest build (current)? If the latter, then I guess you probably want version: current
and will just need to work through all the issues related to changes in the resources.
Craig Anderson (Dec 16 2021 at 02:26):
@Jens Villadsen tried but no. Couldn’t get Sushi working.
Jens Villadsen (Dec 16 2021 at 06:26):
(deleted)
Jens Villadsen (Dec 16 2021 at 11:51):
Grahame Grieve said:
running against R5 current is not supported at this time. And in practice, running against the 4.6.0 isn't either. It's on my list of things to do once I publish the next milestone of R5 in the next week
So crossing fingers and everything else here and just to be clear: The thing on your todo list is to provide support for 4.6.0 (http://hl7.org/fhir/2021May/) in the upcoming week in the IG publisher. Correct?
Jens Villadsen (Dec 16 2021 at 12:38):
@David Hay does clinFHIR use the 4.6.0 package (http://hl7.org/fhir/2021May/) as well for the FSH parts?
David Hay (Dec 16 2021 at 17:21):
yep. When you create a project in GraphBuilder you can select the FHIR version - if you select R5 draft that uses 4.6.0 for the resources (I should make that more explicit). The magic of sushi (actually the API) does the rest!
David Hay (Dec 16 2021 at 17:24):
And in the main UI, at the top left is a link to the spec. In this case, the May2021 version will be shown...
David Hay (Dec 16 2021 at 17:25):
I've only just enabled it, so there may well be issues - ping me if you find any...
Jens Villadsen (Dec 20 2021 at 17:34):
@Grahame Grieve do you have an ETA?
Chris Moesel (Dec 20 2021 at 19:57):
It's not current
, but I think Grahame just released version 5.0.0-snapshot1
based on recent sources. Might that contain what you need? If so, just specify fhirVersion: 5.0.0-snapshot1
in your sushi-config.yaml file.
Jens Villadsen (Dec 21 2021 at 09:47):
@Chris Moesel so sushi-wise that would be 4.6.0 and IGPub-wise it would be 5.0.0-snapshot1 ?
Chris Moesel (Dec 21 2021 at 14:13):
@Jens Villadsen -- you should be able to use 5.0.0-snapshot1
seamlessly across SUSHI and IG Publisher.
Jens Villadsen (Dec 21 2021 at 16:02):
Chris Moesel said:
Jens Villadsen -- you should be able to use
5.0.0-snapshot1
seamlessly across SUSHI and IG Publisher.
Really?
Sushi: error The sushi-config.yaml must specify a supported version of FHIR. Be sure to add "fhirVersion: 4.0.1" (or 4.x.y, as appropriate) to the sushi-config.yaml file. (00:01.0790)
Jens Villadsen (Dec 21 2021 at 16:09):
Thats what sushi tells me when I insert 5.0.0-snapshot1
as version using fsh-sushi v2.2.3 @Chris Moesel
Jens Villadsen (Dec 21 2021 at 19:17):
Same goes for fsh-sushi v2.2.4 @Chris Moesel
Chris Moesel (Dec 21 2021 at 19:46):
Oh. Well... dang. I guess I should have tested it first. I tested 4.3.0-snapshot1 and just assumed that if that worked, so would 5.0.0-snapshot1. I'm sorry for the confusion. We'll try to get a fix in for it.
Chris Moesel (Dec 21 2021 at 21:21):
Chris Moesel (Dec 22 2021 at 21:01):
@Jens Villadsen - This is fixed in the newly released SUSHI 2.2.5. See my release announcement for details.
Craig Anderson (Dec 23 2021 at 20:45):
Jens Villadsen said:
David Hay does clinFHIR use the 4.6.0 package (http://hl7.org/fhir/2021May/) as well for the FSH parts?
@David Hay , can you update ClinFHIR to accept the FHIR R5.0.0-snapshot1? http://hl7.org/fhir/5.0.0-snapshot1/
Jens was able to update the build workflow updated to hl7.fhir.r5.core#5.0.0-snapshot1 but ClinFHIR is still on 4.6.0. There are a few changes in the resources between the two versions.
David Hay (Dec 23 2021 at 21:10):
Yeah I saw that sushi supports that version - will do so, but probably not until next week...
David Hay (Dec 24 2021 at 18:16):
Any known issues with the API? I get error: TypeError: Cannot read property 'startsWith' of undefined on line 168 of processing.js when I pass in an id of 5.0.0-snapshot1
David Hay (Dec 24 2021 at 18:18):
(I haven't yet tried using sushi directly yet so may be my setup - need to go and participate in Christmas morning!). And a merry christmas to you all.... :)
David Hay (Dec 25 2021 at 18:08):
So it works fine when run from vscode - just not through the API...
Mint Thompson (Dec 27 2021 at 14:11):
@David Hay What version are you running? That error should no longer occur starting with version 2.2.5, so if it is, something unusual is happening.
David Hay (Dec 27 2021 at 17:13):
@Mint Thompson - version 2.2.5 The following function (in processing) would seem to limit to the 4.x series...
function isSupportedFHIRVersion(version) {
// For now, allow current or any 4.x version of FHIR except 4.0.0. This is a quick check; not a guarantee. If a user passes
// in an invalid version that passes this test (e.g., 4.99.0), it is still expected to fail when we load dependencies.
//return true
return /current|4\.0\.1|4\.[1-9]\d*.\d+/.test(version);
}
Mint Thompson (Dec 27 2021 at 18:28):
Hmm, that function had its definition changed in SUSHI 2.2.5 (https://github.com/FHIR/sushi/blob/v2.2.5/src/utils/Processing.ts#L28-L32), so if you're still seeing that definition of isSupportedFHIRVersion, there may be something out of alignment in your SUSHI installation.
David Hay (Dec 27 2021 at 19:20):
hmm. here's the response to sushi -v :SUSHI v2.2.5 (implements FHIR Shorthand specification v1.2.0)
I'll try another install and see where I get to. At least I'll know what to look for!
David Hay (Dec 27 2021 at 19:45):
Yep - I had forgotten that I was using a local install of sushi. All good now. Thanks!
Jens Villadsen (Jan 03 2022 at 11:18):
I'm getting a error Failed to load hl7.fhir.r5.core#5.0.0-snapshot1: The package hl7.fhir.r5.core#5.0.0-snapshot1 could not be loaded locally or from the FHIR package registry.
- is that a general issue @Chris Moesel
Chris Moesel (Jan 03 2022 at 13:29):
@Jens Villadsen -- it wasn't an issue when I left for holiday break. I'm just returning today, so I'll have to look if something changed since then. But when we released SUSHI 2.2.5, that was working.
Jens Villadsen (Jan 03 2022 at 13:38):
See also http://build.fhir.org/ig/hl7-eu/gravitate-health/branches/master/failure/build.log
Oliver Egger (Jan 03 2022 at 14:21):
don't know if is related, i get also now error messages for hl7.fhir.r4.core#4.0.1 and our swiss packages with sushi, see: http://build.fhir.org/ig/ahdis/ch-rad-poc/branches/master/failure/build.log
Chris Moesel (Jan 03 2022 at 14:30):
Wow... I will definitely look into this as soon as I get through my mountain of emails. The logs make it seem like something has changed on the package servers -- and things aren't where we expect them to be anymore. That doesn't seem good.
Jens Villadsen (Jan 03 2022 at 15:12):
@Chris Moesel Its probably due to expired certificate. See -> https://chat.fhir.org/#narrow/stream/179252-IG-creation/topic/build.2Efhir.2Eorg.20broken
Chris Moesel (Jan 03 2022 at 15:25):
@Jens Villadsen - yes, that is definitely it! Hopefully someone can fix that certificate. I'm in a meeting now, but when I get out, I can also post a temporary workaround to disable certificate validation locally.
Chris Moesel (Jan 03 2022 at 18:48):
If you are developing locally and STUCK due to the expired certificate, there is a workaround to TURN OFF certificate validation. This is generally a bad idea, because certificate validation is there to protect you from untrusted sources and intercepted communications. BUT... if you really need to move forward, do all of this from the same terminal window:
- Ensure you have already installed the latest SUSHI (
sushi -v
) should report version 2.2.5. If not, install it (npm install -g fsh-sushi
). - Set the NODE_TLS_REJECT_UNAUTHORIZED environment variable to 0. You may need to "export" it so SUSHI can see it. On Mac, you usually use this command:
export NODE_TLS_REJECT_UNAUTHORIZED=0
- Run SUSHI once on your project so it downloads the packages to your local cache.
- Remove the NODE_TLS_REJECT_UNAUTHORIZED environment variable or set its value to 1. On Mac, you usually use this command:
unset NODE_TLS_REJECT_UNAUTHORIZED
or you can useexport NODE_TLS_REJECT_UNAUTHORIZED=1
- Confirm that NODE_TLS_REJECT_UNAUTHORIZED is not set anymore or is set to 1. On Mac, you usually use this command:
echo $NODE_TLS_REJECT_UNAUTHORIZED
and expect either a blank result (if you unset it) or 1 (if you set it to 1).
The steps above minimize your risk by only removing certificate validation temporarily to download the FHIR packages the initial time.
Chris Moesel (Jan 03 2022 at 18:49):
I don't know how to do this in Windows, otherwise I'd tell you (sorry). But the basic intent of the steps should be the same.
Also note that the FHIR auto build server will still fail. I expect that @Josh Mandel does not want to turn off certificate validation on the build server -- so you'll probably need to wait until @Grahame Grieve renews the certificate.
Jens Villadsen (Jan 03 2022 at 20:08):
@Chris Moesel thx - works like a charm!
Jens Villadsen (Jan 04 2022 at 09:42):
@Lynn Laakso ehmm ... so could this sort of thing be a priority for HQ - having CI/CD pipeline that works?
Jens Villadsen (Jan 04 2022 at 14:23):
(deleted)
Lynn Laakso (Jan 04 2022 at 14:31):
@Grahame Grieve
Chris Moesel (Jan 04 2022 at 14:41):
Grahame has not posted on Zulip since December 27, so he appears to be out. Do we know when he will be back? Is there no one else who can renew that expired SSL certificate?
Lynn Laakso (Jan 04 2022 at 14:44):
Sadly, no one else at HQ has administration privileges for fhir.org.
Mark Kramer (Jan 04 2022 at 14:45):
HL7 has to plan for "business continuity without Grahame and Lloyd".
Jens Villadsen (Jan 04 2022 at 15:37):
Yep - we as a community are highly dependent on the tooling and the infrastructure around it
Lynn Laakso (Jan 04 2022 at 15:48):
I have no argument for that. I will send a note to HQ about how to address this with the new CSDO and CSIO
Jens Villadsen (Jan 04 2022 at 16:09):
Feel free to mention that it should be their top priority, IMHO. Dont get me wrong - I love their work and their contributions but the two-men army doesnt scale
Grahame Grieve (Jan 04 2022 at 20:56):
I did have a couple of days off. I expected to get hammered for it, but this issue is a surprise....
Jakob Abada (Jan 05 2022 at 16:53):
Thanks you!!
Grahame Grieve (Jan 05 2022 at 22:43):
should be all fixed now
Jens Villadsen (Jan 05 2022 at 22:47):
wonderful
Jens Villadsen (Jan 05 2022 at 22:52):
@Grahame Grieve pipeline does not agree entirely with you: https://chat.fhir.org/#narrow/stream/179297-committers.2Fnotification/topic/ig-build
Jens Villadsen (Jan 05 2022 at 22:55):
same goes for curl:
curl https://packages.fhir.org/catalog
curl: (60) SSL certificate problem: certificate has expired
More details here: https://curl.haxx.se/docs/sslcerts.html
Grahame Grieve (Jan 05 2022 at 23:10):
indeed. I can't update the certificate on that server. I've asked firely about it
Jens Villadsen (Jan 05 2022 at 23:15):
as in @Ward Weistra ?
Grahame Grieve (Jan 05 2022 at 23:18):
y
Jens Villadsen (Jan 05 2022 at 23:22):
Oh my - and here all along I thought that was only something you could fix :thinking: - that then gives you time to look at all the other things I've burdened you with :grinning_face_with_smiling_eyes:
Chris Moesel (Jan 05 2022 at 23:31):
Is it a different certificate? Or just a matter of applying the already-acquired new certificate to that particular server?
Jens Villadsen (Jan 05 2022 at 23:37):
Looks like a wildcard certificate to me so it should be fine:
image.png
Grahame Grieve (Jan 05 2022 at 23:41):
yes it's just a matter of applying the certificate to the server.
Grahame Grieve (Jan 05 2022 at 23:41):
well, and me giving them the private key
Ward Weistra (Jan 06 2022 at 09:37):
@Grahame Grieve Can you share the necessary documents with me? I'll get them to the right people
Ward Weistra (Jan 10 2022 at 14:13):
@Grahame Grieve I don't think I've received anything yet, right?
Chris Moesel (Jan 10 2022 at 14:46):
If we can get this fixed soon, that would be great. The only reason SUSHI is working at all right now is because when things fail on packages.fhir.org
, it falls back to packages2.fhir.org
, which apparently has the new cert already and also seems to host most of the same packages as packages.fhir.org
. But this is not the ideal workflow, and I'm hoping that the packages on packages2.fhir.org
are the same as the packages on packages.fhir.org
.
Ward Weistra (Jan 11 2022 at 10:42):
Received the certificate from Grahame yesterday. Should now be resolved :thumbs_up:
Patrick Werner (Jan 11 2022 at 10:48):
:party_ball:
Hank Lenzi (Jan 14 2022 at 12:49):
Mark Kramer said:
HL7 has to plan for "business continuity without Grahame and Lloyd".
"bus factor" = 2.
https://en.wikipedia.org/wiki/Bus_factor
Last updated: Apr 12 2022 at 19:14 UTC