FHIR Chat · systax for extention on an extension · shorthand

Stream: shorthand

Topic: systax for extention on an extension


view this post on Zulip Catherine Hosage Norman (Mar 15 2022 at 20:59):

This is a profile on a standard extension. It was fine until I added the container information which defined as an extension on the manufacturing batch extension. I get this error: The sum of mins of slices must be <= max of sliced element, but sum of mins (1) > max (0) of Extension.extension:container.extension. The error repeats for each element in the sub-extension.

Profile: DrugProductmanufacturingBatch
Parent: http://hl7.org/fhir/StructureDefinition/medication-manufacturingBatch
Id: drug-product-manufacturing-batch
Title: "Drug Product Manufacturing Batch"
Description: "This profile defines the details of a batch of medicine."

  • ^url = "https://hl7.org/fhir/pq-cmc/StructureDefinition/extDrugProductMfgBatch"
  • extension[manufacturingDate] 1..1 MS
  • extension[manufacturingDate] ^short = "Manufacturing Date"
  • extension[manufacturingDate].valueDateTime MS
  • extension[manufacturingDateClassification] 1..1 MS
  • extension[manufacturingDateClassification] ^short = "Manufacturing Date Description"
  • extension[manufacturingDateClassification].valueCodeableConcept MS
  • extension[assignedManufacturer] 1..1 MS
  • extension[assignedManufacturer] ^short = "Assigned Manufacturer"
  • extension[assignedManufacturer].valueReference only Reference(MfgTestSiteOrganization)
  • extension[expirationDateClassification] 1..1 MS
  • extension[expirationDateClassification] ^short = "Expiration Date Classification"
  • extension[expirationDateClassification].valueCodeableConcept MS
  • extension[batchUtilization] 1..1 MS
  • extension[batchUtilization] ^short = "Batch Utilization"
  • extension[batchUtilization].valueCodeableConcept MS
  • extension[batchQuantity] 1..1 MS
  • extension[batchQuantity] ^short = "Batch Size"
  • extension[batchQuantity].valueQuantity MS
  • extension[additionalInformation] MS
  • extension[additionalInformation] ^short = "Additional Information"
  • extension[additionalInformation].valueString MS
  • extension[container] 1..* MS
  • extension[container] ^short = "Container"
  • extension[container].extension[lotNumber] 1..1 MS
  • extension[container].extension[lotNumber] ^short = "Container Lot Number"
  • extension[container].extension[lotNumber].string 1..1 MS
  • extension[container].extension[type] 1..1 MS
  • extension[container].extension[type] ^short = "Container Type"
  • extension[container].extension[type].CodeableConcept 1..1 MS
  • extension[container].extension[quantity] 1..1 MS
  • extension[container].extension[quantity] ^short = "Container Fill per Container Size"
  • extension[container].extension[quantity].Ratio 1..1 MS
  • extension[container].extension[closureSystemDescription] 1..1 MS
  • extension[container].extension[closureSystemDescription] ^short = "Closure System Description"
  • extension[container].extension[closureSystemDescription].string 1..1 MS
  • extension[container].extension[closureType] 1..1 MS
  • extension[container].extension[closureType] ^short = "Closure Type"
  • extension[container].extension[closureType].CodeableConcept 1..1 MS

view this post on Zulip Mint Thompson (Mar 16 2022 at 12:51):

interesting! this definitely appears to be an incorrectly reported error, I'm investigating it now.

view this post on Zulip Mint Thompson (Mar 16 2022 at 12:59):

I think I've found the cause: in the definition of the parent extension, the max of Extension.extension:container.extension is, in fact, 0. This is very strange, considering that there are slices defined on this element, but that is why SUSHI is reporting this error.

view this post on Zulip Chris Moesel (Mar 16 2022 at 15:24):

@Mint Thompson is exactly right. The manufacturingBatch extension defines Extension.extension:container.extension with "max": "0":
image.png

view this post on Zulip Chris Moesel (Mar 16 2022 at 15:27):

But it then goes on to specify 5 slices for sub-extensions on it. So, clearly, that seems like an error.

@Grahame Grieve -- is this the sort of thing that the IG Publisher should catch (defining extension 0..0 and then defining a bunch of slices on it)? If we wanted to get this fixed in the extension, who is the right person to contact? Or should we just submit a tracker?

view this post on Zulip John Moehrke (Mar 16 2022 at 15:53):

This seems much like the problem I have been asking about in the slicing and extension on a slice... I have a small example

view this post on Zulip Chris Moesel (Mar 16 2022 at 16:03):

I don't think so. The problem here is pretty clear (or at least seems to be). It doesn't make sense to have something 0..0 and then go and slice it.

view this post on Zulip Jean Duteau (Mar 16 2022 at 16:06):

i'm making the change in a branch. Not sure how that got there. I think I actually created this extension with FSH and then put the resulting SD in the FHIR build. but it was quite a while ago.

view this post on Zulip Catherine Hosage Norman (Mar 24 2022 at 04:42):

Jean, Any progress on this. I just un-commented the lines, tried it and it is not fixed in the latest release of the publisher.

view this post on Zulip Jean Duteau (Mar 24 2022 at 05:41):

it's not a publisher fix, it's how the extension was defined in the build.

view this post on Zulip Catherine Hosage Norman (Mar 24 2022 at 14:03):

I need to get my IG out by the end of the month. Should I write an extension in the IG to add these elements and then change when the build gets fixed?

view this post on Zulip Jean Duteau (Mar 24 2022 at 15:06):

yes, timing wise that's what you'll need to do. I'm not even sure process-wise how we can get this technical correction into the R4 builds.

view this post on Zulip Catherine Hosage Norman (Mar 24 2022 at 17:08):

I am working against R5. None of medication extension was in R4.


Last updated: Apr 12 2022 at 19:14 UTC