You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Bart Decuypere: Hi, we are implementing automatic narrative generation, and after an upgrade from 6.2.5 to a later version (6.4.4 and also 6.6.1), we see that the automatic narrative generation is no longer functioning for R4. (https://hapifhir.io/hapi-fhir/docs/model/narrative_generation.html)
It is no longer possible to assign a template to a resource only, if that resource has a profile assigned to it. The code should be changed to:
.filter(t -> theProfiles.isEmpty() || t.getAppliesToProfiles().isEmpty() || t.getAppliesToProfiles().stream().anyMatch(theProfiles::contains))
In that way, if the properties file does not contain a profile, and the resource does, the template will still apply for the resource. This is the intended behaviour, I think.
Bart Decuypere: Hi, we are implementing automatic narrative generation, and after an upgrade from 6.2.5 to a later version (6.4.4 and also 6.6.1), we see that the automatic narrative generation is no longer functioning for R4. (https://hapifhir.io/hapi-fhir/docs/model/narrative_generation.html)
This line, which should be generating the narrative, is only returning an empty Narrative: https://github.com/hapifhir/org.hl7.fhir.core/blob/ff44e50fc3d66b6c795aa8f2802efd0384265575/org.hl7.fhir.r4/src/main/java/org/hl7/fhir/r4/model/DomainResource.java#L99
We have set our narrative generator on the context, as indicated on (https://hapifhir.io/hapi-fhir/docs/model/narrative_generation.html)
Bart Decuypere: If you need more information from me to be able to help me, please say so! Additional info can be found here: https://chat.fhir.org/#narrow/stream/179167-hapi/topic/upgrade.20hapi-fhir-base.20trouble
Bart Decuypere: I further debugged this issue, and the problem is here:
https://github.com/hapifhir/hapi-fhir/blob/73d6997d214c23f54c2acf66bd6bbd54092609e2/hapi-fhir-base/src/main/java/ca/uhn/fhir/narrative2/NarrativeTemplateManifest.java#L269
It is no longer possible to assign a template to a resource only, if that resource has a profile assigned to it. The code should be changed to:
.filter(t -> theProfiles.isEmpty() || t.getAppliesToProfiles().isEmpty() || t.getAppliesToProfiles().stream().anyMatch(theProfiles::contains))
In that way, if the properties file does not contain a profile, and the resource does, the template will still apply for the resource. This is the intended behaviour, I think.
Bart Decuypere: And the bug was introduced by @james Agnew on Jan 24 of this year: hapifhir/hapi-fhir#4438 .
The text was updated successfully, but these errors were encountered: