From 9272b6eff383d6dc8413f8dc062f70539bcbd005 Mon Sep 17 00:00:00 2001 From: Grahame Grieve Date: Tue, 16 Jul 2024 23:43:36 +0800 Subject: [PATCH 1/5] 2024 07 gg measure validation (#1687) * Fix for validator using wrong property for list determination when parsing json * Fix for R2B Resource.id cardinality problem * Improve MeasureReport validation for checking subject count * work around THO 6.0.0 problem (hack, to be reversed later) * release notes --------- Co-authored-by: Grahame Grieve --- RELEASE_NOTES.md | 9 +- .../fhir/r5/context/BaseWorkerContext.java | 8 ++ .../hl7/fhir/r5/elementmodel/Property.java | 2 +- .../hl7/fhir/r5/renderers/DataRenderer.java | 1 - .../hl7/fhir/r5/utils/PackageHackerR5.java | 10 +++ .../fhir/utilities/i18n/I18nConstants.java | 5 ++ .../src/main/resources/Messages.properties | 55 ++++++------ .../instance/InstanceValidator.java | 2 +- .../instance/type/MeasureValidator.java | 88 +++++++++++++++++-- .../4.0.1/all-systems.cache | 59 ++++++++++++- pom.xml | 2 +- 11 files changed, 204 insertions(+), 37 deletions(-) diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md index 7b06c6ab5..0717e44c8 100644 --- a/RELEASE_NOTES.md +++ b/RELEASE_NOTES.md @@ -1,7 +1,12 @@ ## Validator Changes -* no changes +* work around THO 6.0.0 problem (hack, to be reversed later) +* Improve MeasureReport validation for checking subject count +* Fix for R2B Resource.id cardinality problem +* Fix for validator using wrong property for list determination when parsing json ## Other code changes -* no changes \ No newline at end of file +* no changes + + diff --git a/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/context/BaseWorkerContext.java b/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/context/BaseWorkerContext.java index ac2dfbee0..540c50261 100644 --- a/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/context/BaseWorkerContext.java +++ b/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/context/BaseWorkerContext.java @@ -564,6 +564,7 @@ public abstract class BaseWorkerContext extends I18nBase implements IWorkerConte public Map getNSUrlMap() { if (systemUrlMap == null) { systemUrlMap = new HashMap<>(); + try { List nsl = systems.getList(); for (NamingSystem ns : nsl) { for (NamingSystemUniqueIdComponent uid : ns.getUniqueId()) { @@ -572,6 +573,12 @@ public abstract class BaseWorkerContext extends I18nBase implements IWorkerConte } } } + } catch (Exception e) { + if (!nsFailHasFailed) { + e.printStackTrace(); + nsFailHasFailed = true; + } + } } return systemUrlMap; } @@ -2530,6 +2537,7 @@ public abstract class BaseWorkerContext extends I18nBase implements IWorkerConte protected IWorkerContextManager.IPackageLoadingTracker packageTracker; private boolean forPublication; private boolean cachingAllowed = true; + private static boolean nsFailHasFailed; public Resource fetchResourceById(String type, String uri, FhirPublication fhirVersion) { return fetchResourceById(type, uri); diff --git a/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/elementmodel/Property.java b/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/elementmodel/Property.java index 4440ca536..891b1944b 100644 --- a/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/elementmodel/Property.java +++ b/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/elementmodel/Property.java @@ -280,7 +280,7 @@ public class Property { } public boolean isList() { - return !"1".equals(definition.getMax()); + return !"1".equals(definition.getBase().hasMax() ? definition.getBase().getMax() : definition.getMax()); } public boolean isBaseList() { diff --git a/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/renderers/DataRenderer.java b/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/renderers/DataRenderer.java index 8b38a82b8..67b07b861 100644 --- a/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/renderers/DataRenderer.java +++ b/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/renderers/DataRenderer.java @@ -828,7 +828,6 @@ public class DataRenderer extends Renderer implements CodeResolver { x.tx(context.formatPhrase(RenderingContext.DATA_REND_BASE64, length)); } else { x.code(type.primitiveValue()); - } break; default: diff --git a/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/utils/PackageHackerR5.java b/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/utils/PackageHackerR5.java index 3722757a1..5ea179634 100644 --- a/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/utils/PackageHackerR5.java +++ b/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/utils/PackageHackerR5.java @@ -78,6 +78,16 @@ public class PackageHackerR5 { } } } + // work around an r2b issue + if (packageInfo.getId().equals("hl7.fhir.r2b.core") && r.getType().equals("StructureDefinition")) { + StructureDefinition sd = (StructureDefinition) r.getResource(); + for (ElementDefinition ed : sd.getSnapshot().getElement()) { + if (ed.getPath().equals(sd.getType()+".id")) { + ed.getBase().setMax("1"); + } + } + } + // work around a r4 version of extension pack issue if (packageInfo.getId().equals("hl7.fhir.uv.extensions.r4") && r.getType().equals("StructureDefinition")) { StructureDefinition sd = (StructureDefinition) r.getResource(); diff --git a/org.hl7.fhir.utilities/src/main/java/org/hl7/fhir/utilities/i18n/I18nConstants.java b/org.hl7.fhir.utilities/src/main/java/org/hl7/fhir/utilities/i18n/I18nConstants.java index 15dfc7741..4931e4a1d 100644 --- a/org.hl7.fhir.utilities/src/main/java/org/hl7/fhir/utilities/i18n/I18nConstants.java +++ b/org.hl7.fhir.utilities/src/main/java/org/hl7/fhir/utilities/i18n/I18nConstants.java @@ -1093,4 +1093,9 @@ public class I18nConstants { public static final String IG_DEPENDENCY_EXCEPTION = "IG_DEPENDENCY_EXCEPTION"; public static final String IG_DEPENDENCY_PACKAGE_UNKNOWN = "IG_DEPENDENCY_PACKAGE_UNKNOWN"; public static final String NDJSON_EMPTY_LINE_WARNING = "NDJSON_EMPTY_LINE_WARNING"; + public static final String MEASURE_MR_GRP_POP_COUNT_CANT_CHECK = "MEASURE_MR_GRP_POP_COUNT_CANT_CHECK"; + public static final String MEASURE_MR_GRP_POP_COUNT_NO_REF = "MEASURE_MR_GRP_POP_COUNT_NO_REF"; + public static final String MEASURE_MR_GRP_POP_COUNT_UNRESOLVED = "MEASURE_MR_GRP_POP_COUNT_UNRESOLVED"; + public static final String MEASURE_MR_GRP_POP_COUNT_NO_REF_RES = "MEASURE_MR_GRP_POP_COUNT_NO_REF_RES"; + public static final String MEASURE_MR_GRP_POP_COUNT_REF_UNPROCESSIBLE = "MEASURE_MR_GRP_POP_COUNT_REF_UNPROCESSIBLE"; } diff --git a/org.hl7.fhir.utilities/src/main/resources/Messages.properties b/org.hl7.fhir.utilities/src/main/resources/Messages.properties index ffc174c5e..f7f4899f9 100644 --- a/org.hl7.fhir.utilities/src/main/resources/Messages.properties +++ b/org.hl7.fhir.utilities/src/main/resources/Messages.properties @@ -20,7 +20,7 @@ BUNDLE_BUNDLE_ENTRY_FOUND_MULTIPLE_FRAGMENT = Found {0} matches for fragment {2} BUNDLE_BUNDLE_ENTRY_FULLURL_REQUIRED = Except for transactions and batches, each entry in a Bundle must have a fullUrl which is the identity of the resource in the entry BUNDLE_BUNDLE_ENTRY_MULTIPLE_PROFILES_MULTIPLE_MATCHES = The {1} resource matched more than one of the allowed profiles ({3}) BUNDLE_BUNDLE_ENTRY_MULTIPLE_PROFILES_NO_MATCH = The {1} resource did not match any of the allowed profiles (Type {2}: {3}) -BUNDLE_BUNDLE_ENTRY_MULTIPLE_PROFILES_NO_MATCH_REASON = The {1} resource did not match the profile {2} because: {3} +BUNDLE_BUNDLE_ENTRY_MULTIPLE_PROFILES_NO_MATCH_REASON = The {1} resource did not match the profile {2} because: {3} BUNDLE_BUNDLE_ENTRY_NOTFOUND_APPARENT_one = Can''t find ''{1}'' in the bundle ({2}). Note that there is a resource in the bundle with the same type and id, but it does not match because of the fullUrl based rules around matching relative references (must be ``{3}``) BUNDLE_BUNDLE_ENTRY_NOTFOUND_APPARENT_other = Can''t find ''{1}'' in the bundle ({2}). Note that there are {0} resources in the bundle with the same type and id, but they do not match because of the fullUrl based rules around matching relative references (one of ``{3}``) BUNDLE_BUNDLE_ENTRY_NOTFOUND_FRAGMENT = Can''t find ''{0}'' in the bundle ({1}) @@ -102,7 +102,7 @@ CODESYSTEM_CS_SUPP_INVALID_CODE = The code ''{1}'' is not declared in the base C CODESYSTEM_CS_SUPP_NO_SUPP = The code system is marked as a supplement, but it does not define what code system it supplements CODESYSTEM_CS_UNK_EXPANSION = The code provided ({2}) is not in the expansion in the value set {0}, and a code is required from this value set. The system {1} could not be found. CODESYSTEM_CS_VS_EXP_MISMATCH = CodeSystem {0} has an ''all system'' value set of {1}, but it is an expansion with the wrong number of concepts (found {2}, expected {3}) -CODESYSTEM_DESIGNATION_DISP_CLASH_LANG = The designation ''{0}'' has no use and is in the same language (''{2}''), so is not differentiated from the base display (''{1}'') +CODESYSTEM_DESIGNATION_DISP_CLASH_LANG = The designation ''{0}'' has no use and is in the same language (''{2}''), so is not differentiated from the base display (''{1}'') CODESYSTEM_DESIGNATION_DISP_CLASH_NO_LANG = The designation ''{0}'' has no use and no language, so is not differentiated from the base display (''{1}'') CODESYSTEM_NOT_CONTAINED = CodeSystems are referred to directly from Coding.system, so it''s generally best for them not to be contained resources CODESYSTEM_PROPERTY_BAD_HL7_URI = Unknown CodeSystem Property ''{0}''. If you are creating your own property, do not create it in the HL7 namespace @@ -110,7 +110,7 @@ CODESYSTEM_PROPERTY_CODE_TYPE_MISMATCH = Wrong type ''{2}'': The code ''{0}'' id CODESYSTEM_PROPERTY_CODE_WARNING = If the type is ''code'', then the valueSet property should be provided to clarify what kind of code will be found in the element CODESYSTEM_PROPERTY_DUPLICATE_CODE = A property is already defined with the code ''{0}'' CODESYSTEM_PROPERTY_DUPLICATE_URI = A property is already defined with the URI ''{0}'' -CODESYSTEM_PROPERTY_KNOWN_CODE_SUGGESTIVE = This property has only the standard code (''{0}'') but not the standard URI ''{1}'', so it has no clearly defined meaning in the terminology ecosystem +CODESYSTEM_PROPERTY_KNOWN_CODE_SUGGESTIVE = This property has only the standard code (''{0}'') but not the standard URI ''{1}'', so it has no clearly defined meaning in the terminology ecosystem CODESYSTEM_PROPERTY_NO_VALUE = The property ''{0}'' has no value, and cannot be understood CODESYSTEM_PROPERTY_SYNONYM_CHECK = The synonym ''{0}'' is not also defined in the code system. The Synonym property should only used to declare equivalence to other existing codes CODESYSTEM_PROPERTY_UNDEFINED = The property ''{0}'' has no definition in CodeSystem.property. Many terminology tools won''t know what to do with it @@ -174,7 +174,7 @@ Derived_profile__has_no_type = Derived profile {0} has no type Details_for__matching_against_Profile_ = Details for {0} matching against profile {1} Did_not_find_single_slice_ = Did not find single slice: {0} Did_not_find_type_root_ = Did not find type root: {0} -Differential_does_not_have_a_slice__b_of_____in_profile_ = Differential in profile {5} does not have a slice at {6} (on {0}, position {1} of {2} / {3} / {4}) +Differential_does_not_have_a_slice__b_of_____in_profile_ = Differential in profile {5} does not have a slice at {6} (on {0}, position {1} of {2} / {3} / {4}) Differential_walks_into____but_the_base_does_not_and_there_is_not_a_single_fixed_type_The_type_is__This_is_not_handled_yet = Differential walks into ''{0} (@ {1})'', but the base does not, and there is not a single fixed type. The type is {2}. This is not handled yet Discriminator__is_based_on_element_existence_but_slice__neither_sets_min1_or_max0 = Discriminator ({0}) is based on element existence, but slice {1} neither sets min>=1 or max=0 Discriminator__is_based_on_type_but_slice__in__has_multiple_types_one = @@ -336,7 +336,7 @@ Illegal_path__in_differential_in__name_portion_exceeds_64_chars_in_length = Inva Illegal_path__in_differential_in__name_portion_mising_ = Invalid path ''{0}'' in differential in {1}: name portion missing (''..'') Illegal_path__in_differential_in__no_unicode_whitespace = Invalid path ''{0}'' in differential in {1}: no unicode whitespace Internal_INT_Bad_Type = Unhandled fixed value type {0} -Internal_error___type_not_known_ = Internal error - type not known {0} +Internal_error___type_not_known_ = Internal error - type not known {0} Invalid_slicing__there_is_more_than_one_type_slice_at__but_one_of_them__has_min__1_so_the_other_slices_cannot_exist=Invalid slicing: there is more than one type slice at {0}, but one of them ({1}) has min = 1, so the other slices cannot exist JSON_COMMA_EXTRA = There is an extra comma at the end of the {0} in the JSON JSON_COMMA_MISSING = A Comma is missing in the JSON @@ -371,6 +371,11 @@ MEASURE_MR_GRP_NO_CODE = Group should have a code that matches the group definit MEASURE_MR_GRP_NO_USABLE_CODE = None of the codes provided are usable for comparison - need both system and code on at least one code MEASURE_MR_GRP_NO_WRONG_CODE = The code provided ({0}) does not match the code specified in the measure report ({1}) MEASURE_MR_GRP_POP_COUNT_MISMATCH = Mismatch between count {0} and number of subjects {1} +MEASURE_MR_GRP_POP_COUNT_CANT_CHECK = Unable to check the stated count {0} because the subject list cannot be fully processed ({1}) +MEASURE_MR_GRP_POP_COUNT_NO_REF = Subject reference has no actual reference +MEASURE_MR_GRP_POP_COUNT_UNRESOLVED = Subject reference {0} could not be resolved, and the apparent type is {1} which could not be processed +MEASURE_MR_GRP_POP_COUNT_NO_REF_RES = Subject reference {0} could not be resolved, and so could not be processed +MEASURE_MR_GRP_POP_COUNT_REF_UNPROCESSIBLE = Subject reference {0} resolved to a {1}, which could not be processed MEASURE_MR_GRP_POP_DUPL_CODE = The code for this group population is duplicated with another group MEASURE_MR_GRP_POP_NO_CODE = Group should have a code that matches the group population definition in the measure MEASURE_MR_GRP_POP_NO_COUNT = Count should be present for reports where type is not ''subject-list'' @@ -398,7 +403,7 @@ MEASURE_M_CRITERIA_UNKNOWN = The expression language {0} is not supported, so ca MEASURE_M_GROUP_CODE = Groups should have codes when there is more than one group MEASURE_M_GROUP_POP = Measure Groups should have at least one population MEASURE_M_GROUP_POP_NO_CODE = A measure group population should have a code when there is more than one population -MEASURE_M_GROUP_STRATA_COMP_NO_CODE = A measure group stratifier component should have a code when there is more than one population +MEASURE_M_GROUP_STRATA_COMP_NO_CODE = A measure group stratifier component should have a code when there is more than one population MEASURE_M_GROUP_STRATA_NO_CODE = A measure group stratifier should have a code when there is more than one population MEASURE_M_LIB_UNKNOWN = The Library {0} could not be resolved, so expression validation may not be correct MEASURE_M_NO_GROUPS = A measure should contain at least one group @@ -547,8 +552,8 @@ Reference_REF_CantMatchChoice = Unable to find a match for profile {0} among cho Reference_REF_CantMatchType = Unable to find a match for profile {0} (by type) among choices: {1} Reference_REF_CantResolve = Unable to resolve resource with reference ''{0}'' Reference_REF_CantResolveProfile = Unable to resolve the profile reference ''{0}'' -Reference_REF_Format1 = Relative URLs must be of the format [ResourceName]/[id], or a search URL is allowed ([type]?parameters. Encountered {0}) -Reference_REF_Format2 = Relative URLs must be of the format [ResourceName]/[id]. Encountered {0} +Reference_REF_Format1 = Relative URLs must be of the format [ResourceName]/[id], or a search URL is allowed ([type]?parameters. Encountered {0}) +Reference_REF_Format2 = Relative URLs must be of the format [ResourceName]/[id]. Encountered {0} Reference_REF_MultipleMatches = Found multiple matching profiles for {0} among choices: {1} Reference_REF_NoDisplay = A Reference without an actual reference or identifier should have a display Reference_REF_NoType = Unable to determine type of target resource @@ -624,17 +629,17 @@ SD_VALUE_TYPE_REPEAT_HINT = The repeating element has a {1}. The {1} will apply SD_VALUE_TYPE_REPEAT_WARNING_DOTNET = The repeating element has a {1} value for a primitive type. The DotNet validator will not apply this to all the repeats - this is an error SEARCHPARAMETER_BASE_WRONG = The resource type {1} is not listed as a base in the SearchParameter this is derived from ({0}) SEARCHPARAMETER_EXP_WRONG = The expression ''{2}'' is not compatible with the expression ''{1}'' in the derivedFrom SearchParameter {0}, and this likely indicates that the derivation relationship is not valid -SEARCHPARAMETER_MISSING_COMPONENTS = When the SearchParameter has a type of ''composite'', then the SearchParameter must define two or more components +SEARCHPARAMETER_MISSING_COMPONENTS = When the SearchParameter has a type of ''composite'', then the SearchParameter must define two or more components SEARCHPARAMETER_NOTFOUND = Unable to find the base Search Parameter {0} so can''t check that this SearchParameter is a proper derivation from it SEARCHPARAMETER_TYPE_WRONG = The type {1} is different to the type {0} in the derivedFrom SearchParameter SECURITY_STRING_CONTENT_ERROR = The string value contains text that looks like embedded HTML tags, which are not allowed for security reasons in this context SECURITY_STRING_CONTENT_WARNING = The string value contains text that looks like embedded HTML tags. If this content is rendered to HTML without appropriate post-processing, it may be a security risk SLICING_CANNOT_BE_EVALUATED = Slicing cannot be evaluated: {0} SM_DEPENDENT_PARAM_MODE_MISMATCH = The parameter {0} refers to the variable {1} but it''s mode is {2} which is not the same as the mode required for the group {3} -SM_DEPENDENT_PARAM_NOT_FOUND = The {1} parameter ''{0}'' was not found -SM_DEPENDENT_PARAM_TYPE_MISMATCH = The parameter ''{0}'' refers to the variable ''{1}'' but it''s type is ''{2}'' which is not compatible with the type required for the group ''{3}'', which is ''{4}'' (from map ''{5}'') +SM_DEPENDENT_PARAM_NOT_FOUND = The {1} parameter ''{0}'' was not found +SM_DEPENDENT_PARAM_TYPE_MISMATCH = The parameter ''{0}'' refers to the variable ''{1}'' but it''s type is ''{2}'' which is not compatible with the type required for the group ''{3}'', which is ''{4}'' (from map ''{5}'') SM_DEPENDENT_PARAM_TYPE_MISMATCH_DUPLICATE = The group {0} has already been used with different parameters, so the type checking may be incorrect (other = [{1}]; this = [{2}]) -SM_GROUP_INPUT_DUPLICATE = The name {0} is already used +SM_GROUP_INPUT_DUPLICATE = The name {0} is already used SM_GROUP_INPUT_MODE_INVALID = The group parameter {0} mode {1} isn''t valid SM_GROUP_INPUT_MODE_MISMATCH = The type ''{0}'' has mode ''{1}'' which doesn''t match the structure definition mode of ''{2}'' SM_GROUP_INPUT_NO_TYPE = Group {1} parameter {0} has no type, so the paths cannot be validated @@ -646,7 +651,7 @@ SM_IMPORT_NOT_FOUND = No maps were found to match {0} - validation may be wrong SM_LIST_RULE_ID_ONLY_WHEN_SHARE = A ruleId should only be provided when the rule mode is ''share'' SM_MATCHING_RULEGROUP_NOT_FOUND = Unable to find a default rule for the type pair source={0} and target={1} SM_NAME_INVALID = The name {0} is not valid -SM_NO_LIST_MODE_NEEDED = A list mode should not be provided since this is a rule that can only be executed once +SM_NO_LIST_MODE_NEEDED = A list mode should not be provided since this is a rule that can only be executed once SM_NO_LIST_RULE_ID_NEEDED = A list ruleId should not be provided since this is a rule that can only be executed once SM_ORPHAN_GROUP = The group {0} is not called successfully from within this mapping script, and does not have types on it''s inputs, so type verification is not possible SM_RULEGROUP_NOT_FOUND = The group {0} could not be resolved @@ -679,7 +684,7 @@ SM_TARGET_TRANSFORM_TYPE_UNPROCESSIBLE = The value of the type parameter for {0} SM_TARGET_TRANSLATE_BINDING_SOURCE = The source variable does not have a required binding, so this concept map can''t be checked SM_TARGET_TRANSLATE_BINDING_SOURCE_UNMAPPED = The source value set includes one or more codes that the map does not translate: {0} SM_TARGET_TRANSLATE_BINDING_TARGET = The target variable does not have a required binding, so this concept map can''t be checked -SM_TARGET_TRANSLATE_BINDING_TARGET_WRONG = The map produces one or more codes that the target value set does not include: {0} +SM_TARGET_TRANSLATE_BINDING_TARGET_WRONG = The map produces one or more codes that the target value set does not include: {0} SM_TARGET_TRANSLATE_BINDING_VSE_SOURCE = There was an error expanding the source value set, so this concept map can''t be checked: ''{0}'' SM_TARGET_TRANSLATE_BINDING_VSE_TARGET = There was an error expanding the target value set, so this concept map can''t be checked: ''{0}'' SM_TARGET_TRANSLATE_BINDING_VS_SOURCE = The source variable refers to an unknown value set ''{0}'', so this concept map can''t be checked @@ -767,7 +772,7 @@ TYPE_SPECIFIC_CHECKS_DT_QTY_UCUM_ANNOTATIONS_NOT_IN_UNIT = UCUM Codes that conta TYPE_SPECIFIC_CHECKS_DT_QTY_UCUM_ANNOTATIONS_NO_UNIT = UCUM Codes that contain human readable annotations like {0} can be misleading (e.g. they are ignored when comparing units). Best Practice is not to depend on annotations in the UCUM code, so this usage should be checked, and the Quantity.unit SHOULD contain the annotation TYPE_SPECIFIC_CHECKS_DT_URL_EXAMPLE = Example URLs are not allowed in this context ({0}) TYPE_SPECIFIC_CHECKS_DT_XHTML_MULTIPLE_MATCHES = Hyperlink ''{0}'' at ''{1}'' for ''{2}'' resolves to multiple targets ({3}) -TYPE_SPECIFIER_ABSTRACT_TYPE = The Type specifier {1} specified an abstract type {0} +TYPE_SPECIFIER_ABSTRACT_TYPE = The Type specifier {1} specified an abstract type {0} TYPE_SPECIFIER_ILLEGAL_TYPE = The Type specifier {1} specified an invalid type {0} TYPE_SPECIFIER_NM_ABSTRACT_TYPE = No Type specifier matched, and the underlying type {0} is not abstract TYPE_SPECIFIER_NM_ILLEGAL_TYPE = No Type specifier matched, and the underlying type {0} is not valid @@ -830,7 +835,7 @@ This_element_does_not_match_any_known_slice_ = This element does not match any k This_property_must_be__not_ = The property {2} must be {0}, not {1} (at {3}) This_property_must_be_a_Literal_not_ = This property must be a Literal, not {0} This_property_must_be_a_URI_or_bnode_not_ = This property must be a URI or bnode, not {0} -This_property_must_be_an_Array_not_ = The property {1} must be a JSON Array, not {0} (at {2}) +This_property_must_be_an_Array_not_ = The property {1} must be a JSON Array, not {0} (at {2}) This_property_must_be_an_object_not_ = This property must be an object, not {0} ({1} at {2}) This_property_must_be_an_simple_value_not_ = This property must be a simple value, not {0} ({1} at {2}) Type_Specific_Checks_DT_Base64_Valid = The value ''{0}'' is not a valid Base64 value @@ -887,7 +892,7 @@ UNICODE_BIDI_CONTROLS_CHARS_MATCH = The Unicode sequence has unterminated bi-di UNICODE_XML_BAD_CHARS_one = This content includes the character {1} (hex value). This character is illegal in the XML version of FHIR, and there is generally no valid use for such characters UNICODE_XML_BAD_CHARS_other = This content includes the characters {1} (hex values). These characters are illegal in the XML version of FHIR, and there is generally no valid use for such characters UNKNOWN_CODESYSTEM = A definition for CodeSystem ''{0}'' could not be found, so the code cannot be validated -UNKNOWN_CODESYSTEM_VERSION = A definition for CodeSystem ''{0}'' version ''{1}'' could not be found, so the code cannot be validated. Valid versions: {2} +UNKNOWN_CODESYSTEM_VERSION = A definition for CodeSystem ''{0}'' version ''{1}'' could not be found, so the code cannot be validated. Valid versions: {2} UNKNOWN_CODE_IN_FRAGMENT = Unknown Code ''{0}'' in the system ''{1}'' version ''{2}'' - note that the code system is labeled as a fragment, so the code may be valid in some other fragment UNRECOGNISED_PROPERTY_TYPE = Invalid JSON type {0} for the element {1}; valid types = {2} UNRECOGNISED_PROPERTY_TYPE_WRONG = Invalid type {2} for the element {1}; valid types = {3}, JSON type = {0} @@ -919,9 +924,9 @@ Unable_to_resolve_slice_matching__slice_matching_by_value_set_not_done = Unable Unable_to_resolve_system__no_value_set = Unable to resolve system - no value set Unable_to_resolve_system__value_set_expansion_has_multiple_systems = The System URI could not be determined for the code ''{0}'' in the ValueSet ''{1}'': value set expansion has multiple systems Unable_to_resolve_system__value_set_has_imports = The System URI could not be determined for the code ''{0}'' in the ValueSet ''{1}'': value set has imports -Unable_to_resolve_system__value_set_has_include_with_filter = The System URI could not be determined for the code ''{0}'' in the ValueSet ''{1}'': include #{2} has a filter on system {3}: {4} +Unable_to_resolve_system__value_set_has_include_with_filter = The System URI could not be determined for the code ''{0}'' in the ValueSet ''{1}'': include #{2} has a filter on system {3}: {4} Unable_to_resolve_system__value_set_has_include_with_no_system = Unable to resolve system - value set {0} include #{1} has no system -Unable_to_resolve_system__value_set_has_include_with_unknown_system = The System URI could not be determined for the code ''{0}'' in the ValueSet ''{1}'': include #{2} has system {3} which could not be found, and the server returned error {4} +Unable_to_resolve_system__value_set_has_include_with_unknown_system = The System URI could not be determined for the code ''{0}'' in the ValueSet ''{1}'': include #{2} has system {3} which could not be found, and the server returned error {4} Unable_to_resolve_system__value_set_has_multiple_matches = The System URI could not be determined for the code ''{0}'' in the ValueSet ''{1}'': value set expansion has multiple matches: {2} Unable_to_resolve_system__value_set_has_no_includes_or_expansion = The System URI could not be determined for the code ''{0}'' in the ValueSet ''{1}'': value set has no includes or expansion Unable_to_resolve_value_Set_ = A definition for the value Set ''{0}'' could not be found @@ -991,7 +996,7 @@ VALUESET_BAD_FILTER_VALUE_VALID_REGEX = The value for a filter based on property VALUESET_BAD_PROPERTY_NO_REGEX = Cannot apply a regex filter to the property ''{0}'' (usually regex filters are applied to the codes, or a named property of the code system) VALUESET_CIRCULAR_REFERENCE = Found a circularity pointing to {0} processing ValueSet with pathway {1} VALUESET_CONCEPT_DISPLAY_PRESENCE_MIXED = This include has some concepts with displays and some without - check that this is what is intended -VALUESET_CONCEPT_DISPLAY_SCT_TAG_MIXED = This SNOMED-CT based include has some concepts with semantic tags (FSN terms) and some without (preferred terms) - check that this is what is intended (examples for FSN: {0} and examples for no FSN: {1}) +VALUESET_CONCEPT_DISPLAY_SCT_TAG_MIXED = This SNOMED-CT based include has some concepts with semantic tags (FSN terms) and some without (preferred terms) - check that this is what is intended (examples for FSN: {0} and examples for no FSN: {1}) VALUESET_EXAMPLE_SYSTEM_ERROR = Example System ''{0}'' specified, which is illegal. Concepts and Filters can''t be checked VALUESET_EXAMPLE_SYSTEM_HINT = Example System ''{0}'' specified, so Concepts and Filters can''t be checked VALUESET_IMPORT_UNION_INTERSECTION = This value set has a single include with multiple imported value sets. Per issue https://jira.hl7.org/browse/FHIR-25179, there has been confusion in the past whether these value sets are unioned or intersectioned. If this value set is contained in a package published prior to March 31 2022, it will be treated as a union, otherwise it will be treated as an intersection. If want a union, split the value set imports across multiple includes @@ -1108,14 +1113,14 @@ SD_TYPE_PARAMETER_INVALID = The type definition ''{2}'' has a type parameter ''{ SD_TYPE_PARAMETER_INVALID_REF = The type ''{0}'' is a reference to ''{1}'' which has a type parameter ''{2}'' with a base type of {3} but the type parameter provided is ''{4}'' which is not the right type SD_TYPE_PARAM_NOT_SPECIFIED = The type ''{0}'' at {3} is a reference to ''{1}'' which needs a type parameter ''{2}'' but a type parameter is not provided for ''{2}'' SD_TYPE_PARAMETER_ABSTRACT_WARNING = The type ''{0}'' at {3} refers to the abstract type ''{1}'' but the context is not an abstract type - this is usually an error -IG_DEPENDENCY_DIRECT = The URL should refer directly to the ImplementationGuide resource (e.g. include ''/ImplementationGuide/'') -IG_DEPENDENCY_INVALID_PACKAGEID = The packageId {0} is not valid -IG_DEPENDENCY_CLASH_PACKAGEID = The canonical URL {0} points to the package {1} which is inconsistent with the stated packageId of {2} -IG_DEPENDENCY_CLASH_CANONICAL = The packageId {0} points to the canonical {1} which is inconsistent with the stated canonical of {2} +IG_DEPENDENCY_DIRECT = The URL should refer directly to the ImplementationGuide resource (e.g. include ''/ImplementationGuide/'') +IG_DEPENDENCY_INVALID_PACKAGEID = The packageId {0} is not valid +IG_DEPENDENCY_CLASH_PACKAGEID = The canonical URL {0} points to the package {1} which is inconsistent with the stated packageId of {2} +IG_DEPENDENCY_CLASH_CANONICAL = The packageId {0} points to the canonical {1} which is inconsistent with the stated canonical of {2} IG_DEPENDENCY_NO_PACKAGE = No NPM package id could be determined so the version consistency can't be checked IG_NO_VERSION = No fhir version was specified for the IG so the version consistency can't be checked IG_DEPENDENCY_NO_VERSION = No version was specified for the package so the version consistency can't be checked -IG_DEPENDENCY_INVALID_PACKAGE_VERSION = The version {0} is not a valid NPM package version +IG_DEPENDENCY_INVALID_PACKAGE_VERSION = The version {0} is not a valid NPM package version IG_DEPENDENCY_PACKAGE_UNKNOWN = The package {0} could not be found so the version consistency can't be checked IG_DEPENDENCY_VERSION_ERROR = The ImplementationGuide is based on FHIR version {0} but package {1} is based on FHIR version {2}. Use the package {3} instead IG_DEPENDENCY_VERSION_WARNING = The ImplementationGuide is based on FHIR version {0} but package {1} is based on FHIR version {2}. In general, this version mismatch should be avoided - some tools will try to make this work with variable degrees of success, but others will not even try diff --git a/org.hl7.fhir.validation/src/main/java/org/hl7/fhir/validation/instance/InstanceValidator.java b/org.hl7.fhir.validation/src/main/java/org/hl7/fhir/validation/instance/InstanceValidator.java index e0ec55f35..a948ba214 100644 --- a/org.hl7.fhir.validation/src/main/java/org/hl7/fhir/validation/instance/InstanceValidator.java +++ b/org.hl7.fhir.validation/src/main/java/org/hl7/fhir/validation/instance/InstanceValidator.java @@ -4564,7 +4564,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat return true; } - private ResolvedReference localResolve(String ref, NodeStack stack, List errors, String path, Element rootResource, Element groupingResource, Element source, BooleanHolder bh) { + public ResolvedReference localResolve(String ref, NodeStack stack, List errors, String path, Element rootResource, Element groupingResource, Element source, BooleanHolder bh) { if (ref.startsWith("#")) { // work back through the parent list, tracking the stack as we go // really, there should only be one level for this (contained resources cannot contain diff --git a/org.hl7.fhir.validation/src/main/java/org/hl7/fhir/validation/instance/type/MeasureValidator.java b/org.hl7.fhir.validation/src/main/java/org/hl7/fhir/validation/instance/type/MeasureValidator.java index 314e2009d..ce526675e 100644 --- a/org.hl7.fhir.validation/src/main/java/org/hl7/fhir/validation/instance/type/MeasureValidator.java +++ b/org.hl7.fhir.validation/src/main/java/org/hl7/fhir/validation/instance/type/MeasureValidator.java @@ -25,6 +25,7 @@ import org.hl7.fhir.r5.model.Measure.MeasureGroupStratifierComponent; import org.hl7.fhir.r5.model.Resource; import org.hl7.fhir.r5.renderers.DataRenderer; import org.hl7.fhir.r5.utils.ToolingExtensions; +import org.hl7.fhir.utilities.CommaSeparatedStringBuilder; import org.hl7.fhir.utilities.FhirPublication; import org.hl7.fhir.utilities.Utilities; import org.hl7.fhir.utilities.i18n.I18nConstants; @@ -32,7 +33,10 @@ import org.hl7.fhir.utilities.validation.ValidationMessage; import org.hl7.fhir.utilities.validation.ValidationMessage.IssueType; import org.hl7.fhir.utilities.xml.XMLUtil; import org.hl7.fhir.validation.BaseValidator; +import org.hl7.fhir.validation.BaseValidator.BooleanHolder; +import org.hl7.fhir.validation.instance.InstanceValidator; import org.hl7.fhir.validation.instance.utils.NodeStack; +import org.hl7.fhir.validation.instance.utils.ResolvedReference; import org.hl7.fhir.validation.instance.utils.ValidationContext; import org.w3c.dom.Document; @@ -493,19 +497,93 @@ public class MeasureValidator extends BaseValidator { private boolean validateMeasureReportGroupPopulation(ValidationContext hostContext, MeasureContext m, MeasureGroupPopulationComponent mgp, List errors, Element mrgp, NodeStack ns, boolean inProgress) { boolean ok = true; - List sr = mrgp.getChildrenByName("subjectResults"); + List srl = mrgp.getChildrenByName("subjectResults"); if ("subject-list".equals(m.reportType())) { try { - int c = Integer.parseInt(mrgp.getChildValue("count")); - ok = rule(errors, NO_RULE_DATE, IssueType.BUSINESSRULE, mrgp.line(), mrgp.col(), ns.getLiteralPath(), c == sr.size(), I18nConstants.MEASURE_MR_GRP_POP_COUNT_MISMATCH, c, sr.size()) && ok; + int subCount = 0; + CommaSeparatedStringBuilder b = new CommaSeparatedStringBuilder("; "); + for (Element sr : srl) { + subCount = addToSubjectCount(subCount, hostContext, sr, m, ns, b); + } + if (mrgp.hasChild("count")) { + int c = Integer.parseInt(mrgp.getChildValue("count")); + if (subCount > -1) { + ok = rule(errors, NO_RULE_DATE, IssueType.BUSINESSRULE, mrgp.line(), mrgp.col(), ns.getLiteralPath(), c == subCount, I18nConstants.MEASURE_MR_GRP_POP_COUNT_MISMATCH, c, subCount) && ok; + } else { + hint(errors, NO_RULE_DATE, IssueType.BUSINESSRULE, mrgp.line(), mrgp.col(), ns.getLiteralPath(), false, I18nConstants.MEASURE_MR_GRP_POP_COUNT_CANT_CHECK, c, b.toString()); + } + } } catch (Exception e) { // nothing; that'll be because count is not valid, and that's a different error or its missing and we don't care } } else { - ok = rule(errors, NO_RULE_DATE, IssueType.BUSINESSRULE, mrgp.line(), mrgp.col(), ns.getLiteralPath(), sr.size() == 0, I18nConstants.MEASURE_MR_GRP_POP_NO_SUBJECTS) && ok; + ok = rule(errors, NO_RULE_DATE, IssueType.BUSINESSRULE, mrgp.line(), mrgp.col(), ns.getLiteralPath(), srl.size() == 0, I18nConstants.MEASURE_MR_GRP_POP_NO_SUBJECTS) && ok; warning(errors, NO_RULE_DATE, IssueType.BUSINESSRULE, mrgp.line(), mrgp.col(), ns.getLiteralPath(), mrgp.hasChild("count", false), I18nConstants.MEASURE_MR_GRP_POP_NO_COUNT); } - return ok; + return ok; + } + + private int addToSubjectCount(int subCount, ValidationContext valContext, Element sr, MeasureContext m, NodeStack ns, CommaSeparatedStringBuilder b) throws FHIRException, IOException { + if (subCount < 0) { + return -1; + } + + String ref = sr.getNamedChildValue("reference"); + if (ref == null) { + b.append(context.formatMessage(I18nConstants.MEASURE_MR_GRP_POP_COUNT_NO_REF)); + return -1; + } + BooleanHolder bh = new BooleanHolder(); + ResolvedReference rr = ((InstanceValidator) parent).localResolve(ref, ns, new ArrayList<>(), ns.getLiteralPath(), valContext.getRootResource(), valContext.getGroupingResource(), sr, bh); + Element tgt; + if (rr != null) { + tgt = rr.getResource(); + } else { + tgt = fetcher.fetch(((InstanceValidator) parent), valContext.getAppContext(), ref); + } + if (tgt == null) { + // we couldn't resolve it, but we'll draw our own conclusion from the literal URL if we can. + String[] parts = ref.split("\\/"); + if (parts.length == 2 && context.getResourceNamesAsSet().contains(parts[0])) { + switch (parts[0]) { + case "Patient": + case "Practitioner": + case "Person": + case "PractitionerRole": + case "RelatedPerson": + return subCount + 1; + case "List": + b.append(context.formatMessage(I18nConstants.MEASURE_MR_GRP_POP_COUNT_UNRESOLVED, "List", ref)); + return -1; // for now + case "Group": + b.append(context.formatMessage(I18nConstants.MEASURE_MR_GRP_POP_COUNT_UNRESOLVED, "Group", ref)); + return -1; // for now + default: + b.append(context.formatMessage(I18nConstants.MEASURE_MR_GRP_POP_COUNT_UNRESOLVED, parts[0], ref)); + return -1; + } + } else { + // add information / hint? + b.append(context.formatMessage(I18nConstants.MEASURE_MR_GRP_POP_COUNT_NO_REF_RES, ref)); + return -1; + } + } + switch (tgt.fhirType()) { + case "Patient": + case "Practitioner": + case "Person": + case "PractitionerRole": + case "RelatedPerson": + return subCount + 1; + case "List": + return subCount + tgt.getChildren("entry").size(); + case "Group": + b.append(context.formatMessage(I18nConstants.MEASURE_MR_GRP_POP_COUNT_REF_UNPROCESSIBLE, "Group", ref)); + return -1; // for now + default: + b.append(context.formatMessage(I18nConstants.MEASURE_MR_GRP_POP_COUNT_REF_UNPROCESSIBLE, tgt.fhirType(), ref)); + return -1; + } } private boolean validateMeasureReportGroupStratifiers(ValidationContext hostContext, MeasureContext m, MeasureGroupComponent mg, List errors, Element mrg, NodeStack stack, boolean inProgress) { diff --git a/org.hl7.fhir.validation/src/test/resources/txCache/org.hl7.fhir.validation/4.0.1/all-systems.cache b/org.hl7.fhir.validation/src/test/resources/txCache/org.hl7.fhir.validation/4.0.1/all-systems.cache index c611af8ff..e7d68aabd 100644 --- a/org.hl7.fhir.validation/src/test/resources/txCache/org.hl7.fhir.validation/4.0.1/all-systems.cache +++ b/org.hl7.fhir.validation/src/test/resources/txCache/org.hl7.fhir.validation/4.0.1/all-systems.cache @@ -3587,10 +3587,67 @@ v: { "code" : "en-AU", "system" : "urn:ietf:bcp:47", "server" : "http://tx-dev.fhir.org/r4", - "unknown-systems" : "", "issues" : { "resourceType" : "OperationOutcome" } } ------------------------------------------------------------------------------------- +{"code" : { + "system" : "urn:oid:1.2.840.114350.1.72.1.7.7.10.696784.13260", + "code" : "1", + "display" : "Surgery Case" +}, "url": "http://terminology.hl7.org/ValueSet/v3-ActEncounterCode", "version": "3.0.0", "langs":"", "useServer":"true", "useClient":"true", "guessSystem":"false", "activeOnly":"false", "membershipOnly":"false", "displayWarningMode":"false", "versionFlexible":"false", "profile": { + "resourceType" : "Parameters", + "parameter" : [{ + "name" : "profile-url", + "valueString" : "http://hl7.org/fhir/ExpansionProfile/dc8fd4bc-091a-424a-8a3b-6198ef146891" + }] +}}#### +v: { + "code" : "1", + "severity" : "error", + "error" : "A definition for CodeSystem 'urn:oid:1.2.840.114350.1.72.1.7.7.10.696784.13260' could not be found, so the code cannot be validated; The provided code 'urn:oid:1.2.840.114350.1.72.1.7.7.10.696784.13260#1 ('Surgery Case')' was not found in the value set 'http://terminology.hl7.org/ValueSet/v3-ActEncounterCode|3.0.0'", + "class" : "UNKNOWN", + "server" : "http://tx-dev.fhir.org/r4", + "unknown-systems" : "urn:oid:1.2.840.114350.1.72.1.7.7.10.696784.13260", + "issues" : { + "resourceType" : "OperationOutcome", + "issue" : [{ + "extension" : [{ + "url" : "http://hl7.org/fhir/StructureDefinition/operationoutcome-issue-server", + "valueUrl" : "http://tx-dev.fhir.org/r4" + }], + "severity" : "error", + "code" : "not-found", + "details" : { + "coding" : [{ + "system" : "http://hl7.org/fhir/tools/CodeSystem/tx-issue-type", + "code" : "not-found" + }], + "text" : "A definition for CodeSystem 'urn:oid:1.2.840.114350.1.72.1.7.7.10.696784.13260' could not be found, so the code cannot be validated" + }, + "location" : ["Coding.system"], + "expression" : ["Coding.system"] + }, + { + "extension" : [{ + "url" : "http://hl7.org/fhir/StructureDefinition/operationoutcome-issue-server", + "valueUrl" : "http://tx-dev.fhir.org/r4" + }], + "severity" : "error", + "code" : "code-invalid", + "details" : { + "coding" : [{ + "system" : "http://hl7.org/fhir/tools/CodeSystem/tx-issue-type", + "code" : "not-in-vs" + }], + "text" : "The provided code 'urn:oid:1.2.840.114350.1.72.1.7.7.10.696784.13260#1 ('Surgery Case')' was not found in the value set 'http://terminology.hl7.org/ValueSet/v3-ActEncounterCode|3.0.0'" + }, + "location" : ["Coding.code"], + "expression" : ["Coding.code"] + }] +} + +} +------------------------------------------------------------------------------------- diff --git a/pom.xml b/pom.xml index 6ea8fef2d..c6bc66c20 100644 --- a/pom.xml +++ b/pom.xml @@ -21,7 +21,7 @@ 1.26.0 32.0.1-jre 6.4.1 - 1.5.15 + 1.5.16-SNAPSHOT 2.17.0 5.9.2 1.8.2 From 332af386ce1865a7a38632803eaa2272885d8ce5 Mon Sep 17 00:00:00 2001 From: dotasek Date: Tue, 16 Jul 2024 12:47:46 -0400 Subject: [PATCH 2/5] Bump test cases to release version ***NO_CI*** --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index c6bc66c20..21462a837 100644 --- a/pom.xml +++ b/pom.xml @@ -21,7 +21,7 @@ 1.26.0 32.0.1-jre 6.4.1 - 1.5.16-SNAPSHOT + 1.5.16 2.17.0 5.9.2 1.8.2 From cf2b25eb299814fe8b3b48359eaf9bd99da90de9 Mon Sep 17 00:00:00 2001 From: markiantorno Date: Tue, 16 Jul 2024 17:32:26 +0000 Subject: [PATCH 3/5] Release: v6.3.17 ## Validator Changes * work around THO 6.0.0 problem (hack, to be reversed later) * Improve MeasureReport validation for checking subject count * Fix for R2B Resource.id cardinality problem * Fix for validator using wrong property for list determination when parsing json ## Other code changes * no changes ***NO_CI*** --- org.hl7.fhir.convertors/pom.xml | 2 +- org.hl7.fhir.dstu2/pom.xml | 2 +- org.hl7.fhir.dstu2016may/pom.xml | 2 +- org.hl7.fhir.dstu3/pom.xml | 2 +- org.hl7.fhir.r4/pom.xml | 2 +- org.hl7.fhir.r4b/pom.xml | 2 +- org.hl7.fhir.r5/pom.xml | 2 +- org.hl7.fhir.report/pom.xml | 2 +- org.hl7.fhir.utilities/pom.xml | 2 +- org.hl7.fhir.validation.cli/pom.xml | 2 +- org.hl7.fhir.validation/pom.xml | 2 +- pom.xml | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-) diff --git a/org.hl7.fhir.convertors/pom.xml b/org.hl7.fhir.convertors/pom.xml index 00f1954bb..2ece60aa5 100644 --- a/org.hl7.fhir.convertors/pom.xml +++ b/org.hl7.fhir.convertors/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17-SNAPSHOT + 6.3.17 ../pom.xml diff --git a/org.hl7.fhir.dstu2/pom.xml b/org.hl7.fhir.dstu2/pom.xml index 691987acf..d2eb2fbc2 100644 --- a/org.hl7.fhir.dstu2/pom.xml +++ b/org.hl7.fhir.dstu2/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17-SNAPSHOT + 6.3.17 ../pom.xml diff --git a/org.hl7.fhir.dstu2016may/pom.xml b/org.hl7.fhir.dstu2016may/pom.xml index ef09431de..c984d307e 100644 --- a/org.hl7.fhir.dstu2016may/pom.xml +++ b/org.hl7.fhir.dstu2016may/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17-SNAPSHOT + 6.3.17 ../pom.xml diff --git a/org.hl7.fhir.dstu3/pom.xml b/org.hl7.fhir.dstu3/pom.xml index 9e2857d5f..dc169ed83 100644 --- a/org.hl7.fhir.dstu3/pom.xml +++ b/org.hl7.fhir.dstu3/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17-SNAPSHOT + 6.3.17 ../pom.xml diff --git a/org.hl7.fhir.r4/pom.xml b/org.hl7.fhir.r4/pom.xml index fb7e9e9b1..37ab16826 100644 --- a/org.hl7.fhir.r4/pom.xml +++ b/org.hl7.fhir.r4/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17-SNAPSHOT + 6.3.17 ../pom.xml diff --git a/org.hl7.fhir.r4b/pom.xml b/org.hl7.fhir.r4b/pom.xml index 5536d8478..acd1d5ca7 100644 --- a/org.hl7.fhir.r4b/pom.xml +++ b/org.hl7.fhir.r4b/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17-SNAPSHOT + 6.3.17 ../pom.xml diff --git a/org.hl7.fhir.r5/pom.xml b/org.hl7.fhir.r5/pom.xml index 4ba9b01ac..3987b20d0 100644 --- a/org.hl7.fhir.r5/pom.xml +++ b/org.hl7.fhir.r5/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17-SNAPSHOT + 6.3.17 ../pom.xml diff --git a/org.hl7.fhir.report/pom.xml b/org.hl7.fhir.report/pom.xml index 7c5c8965b..7a502056a 100644 --- a/org.hl7.fhir.report/pom.xml +++ b/org.hl7.fhir.report/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17-SNAPSHOT + 6.3.17 ../pom.xml diff --git a/org.hl7.fhir.utilities/pom.xml b/org.hl7.fhir.utilities/pom.xml index c94c4bd78..d72c5c402 100644 --- a/org.hl7.fhir.utilities/pom.xml +++ b/org.hl7.fhir.utilities/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17-SNAPSHOT + 6.3.17 ../pom.xml diff --git a/org.hl7.fhir.validation.cli/pom.xml b/org.hl7.fhir.validation.cli/pom.xml index daaadaccc..8fb1b8f71 100644 --- a/org.hl7.fhir.validation.cli/pom.xml +++ b/org.hl7.fhir.validation.cli/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17-SNAPSHOT + 6.3.17 ../pom.xml diff --git a/org.hl7.fhir.validation/pom.xml b/org.hl7.fhir.validation/pom.xml index a24629a70..579af2c54 100644 --- a/org.hl7.fhir.validation/pom.xml +++ b/org.hl7.fhir.validation/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17-SNAPSHOT + 6.3.17 ../pom.xml diff --git a/pom.xml b/pom.xml index 21462a837..3929b28af 100644 --- a/pom.xml +++ b/pom.xml @@ -14,7 +14,7 @@ HAPI FHIR --> org.hl7.fhir.core - 6.3.17-SNAPSHOT + 6.3.17 pom From 0722d728ae03ed4071a4fb46006cee94754dd156 Mon Sep 17 00:00:00 2001 From: markiantorno Date: Tue, 16 Jul 2024 18:20:14 +0000 Subject: [PATCH 4/5] Updating version to: 6.3.18-SNAPSHOT and incrementing test cases dependency. --- RELEASE_NOTES.md | 9 ++------- org.hl7.fhir.convertors/pom.xml | 2 +- org.hl7.fhir.dstu2/pom.xml | 2 +- org.hl7.fhir.dstu2016may/pom.xml | 2 +- org.hl7.fhir.dstu3/pom.xml | 2 +- org.hl7.fhir.r4/pom.xml | 2 +- org.hl7.fhir.r4b/pom.xml | 2 +- org.hl7.fhir.r5/pom.xml | 2 +- org.hl7.fhir.report/pom.xml | 2 +- org.hl7.fhir.utilities/pom.xml | 2 +- org.hl7.fhir.validation.cli/pom.xml | 2 +- org.hl7.fhir.validation/pom.xml | 2 +- pom.xml | 2 +- 13 files changed, 14 insertions(+), 19 deletions(-) diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md index 0717e44c8..7b06c6ab5 100644 --- a/RELEASE_NOTES.md +++ b/RELEASE_NOTES.md @@ -1,12 +1,7 @@ ## Validator Changes -* work around THO 6.0.0 problem (hack, to be reversed later) -* Improve MeasureReport validation for checking subject count -* Fix for R2B Resource.id cardinality problem -* Fix for validator using wrong property for list determination when parsing json - -## Other code changes - * no changes +## Other code changes +* no changes \ No newline at end of file diff --git a/org.hl7.fhir.convertors/pom.xml b/org.hl7.fhir.convertors/pom.xml index 2ece60aa5..4e468c855 100644 --- a/org.hl7.fhir.convertors/pom.xml +++ b/org.hl7.fhir.convertors/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17 + 6.3.18-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.dstu2/pom.xml b/org.hl7.fhir.dstu2/pom.xml index d2eb2fbc2..e150e70c4 100644 --- a/org.hl7.fhir.dstu2/pom.xml +++ b/org.hl7.fhir.dstu2/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17 + 6.3.18-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.dstu2016may/pom.xml b/org.hl7.fhir.dstu2016may/pom.xml index c984d307e..0ece8835b 100644 --- a/org.hl7.fhir.dstu2016may/pom.xml +++ b/org.hl7.fhir.dstu2016may/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17 + 6.3.18-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.dstu3/pom.xml b/org.hl7.fhir.dstu3/pom.xml index dc169ed83..92ca90f77 100644 --- a/org.hl7.fhir.dstu3/pom.xml +++ b/org.hl7.fhir.dstu3/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17 + 6.3.18-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.r4/pom.xml b/org.hl7.fhir.r4/pom.xml index 37ab16826..03c7bc1c6 100644 --- a/org.hl7.fhir.r4/pom.xml +++ b/org.hl7.fhir.r4/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17 + 6.3.18-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.r4b/pom.xml b/org.hl7.fhir.r4b/pom.xml index acd1d5ca7..6eb9b978b 100644 --- a/org.hl7.fhir.r4b/pom.xml +++ b/org.hl7.fhir.r4b/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17 + 6.3.18-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.r5/pom.xml b/org.hl7.fhir.r5/pom.xml index 3987b20d0..986926024 100644 --- a/org.hl7.fhir.r5/pom.xml +++ b/org.hl7.fhir.r5/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17 + 6.3.18-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.report/pom.xml b/org.hl7.fhir.report/pom.xml index 7a502056a..02f4536d5 100644 --- a/org.hl7.fhir.report/pom.xml +++ b/org.hl7.fhir.report/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17 + 6.3.18-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.utilities/pom.xml b/org.hl7.fhir.utilities/pom.xml index d72c5c402..8aceebda8 100644 --- a/org.hl7.fhir.utilities/pom.xml +++ b/org.hl7.fhir.utilities/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17 + 6.3.18-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.validation.cli/pom.xml b/org.hl7.fhir.validation.cli/pom.xml index 8fb1b8f71..87bd293b4 100644 --- a/org.hl7.fhir.validation.cli/pom.xml +++ b/org.hl7.fhir.validation.cli/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17 + 6.3.18-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.validation/pom.xml b/org.hl7.fhir.validation/pom.xml index 579af2c54..157e101f8 100644 --- a/org.hl7.fhir.validation/pom.xml +++ b/org.hl7.fhir.validation/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 6.3.17 + 6.3.18-SNAPSHOT ../pom.xml diff --git a/pom.xml b/pom.xml index 3929b28af..02ae4285d 100644 --- a/pom.xml +++ b/pom.xml @@ -14,7 +14,7 @@ HAPI FHIR --> org.hl7.fhir.core - 6.3.17 + 6.3.18-SNAPSHOT pom From 84fc25efa3a6617b044872036b8d7bd50a17603e Mon Sep 17 00:00:00 2001 From: Lloyd McKenzie Date: Tue, 16 Jul 2024 21:35:41 -0600 Subject: [PATCH 5/5] Fix issue with rendering OperationOutcomes that don't have 'detail' --- .../org/hl7/fhir/r5/renderers/OperationOutcomeRenderer.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/renderers/OperationOutcomeRenderer.java b/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/renderers/OperationOutcomeRenderer.java index b725fa17f..8e9e8ef6b 100644 --- a/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/renderers/OperationOutcomeRenderer.java +++ b/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/renderers/OperationOutcomeRenderer.java @@ -88,8 +88,9 @@ public class OperationOutcomeRenderer extends ResourceRenderer { d = true; td.addText(s.primitiveValue()); } - tr.td().addText(getTranslatedCode(i.child("code"))); - tr.td().addText(i.child("details").primitiveValue("text")); + tr.td().addText(getTranslatedCode(i.child("code"))); + if (i.has("details")) + tr.td().addText(i.child("details").primitiveValue("text")); smartAddText(tr.td(), i.primitiveValue("diagnostics")); if (hasSource) { ResourceWrapper ext = i.extension(ToolingExtensions.EXT_ISSUE_SOURCE);