diff --git a/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/terminologies/ValueSetCheckerSimple.java b/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/terminologies/ValueSetCheckerSimple.java index 4b1428ce3..4394866f5 100644 --- a/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/terminologies/ValueSetCheckerSimple.java +++ b/org.hl7.fhir.r5/src/main/java/org/hl7/fhir/r5/terminologies/ValueSetCheckerSimple.java @@ -359,8 +359,13 @@ public class ValueSetCheckerSimple extends ValueSetWorker implements ValueSetChe } if (!inExpansion) { if (valueset != null && valueset.hasExpansion()) { - String msg = context.formatMessage(I18nConstants.CODESYSTEM_CS_UNK_EXPANSION, valueset.getUrl(), code.getCode().toString(), code.getSystem()); - return new ValidationResult(IssueSeverity.ERROR, msg, makeIssue(IssueSeverity.ERROR, IssueType.NOTFOUND, path, msg)); + String msg = context.formatMessage(I18nConstants.CODESYSTEM_CS_UNK_EXPANSION, + valueset.getUrl(), + code.getSystem(), + code.getCode().toString()); + List issues = new ArrayList<>(); + issues.addAll(makeIssue(IssueSeverity.ERROR, IssueType.NOTFOUND, path, msg)); + throw new VSCheckerException(msg, issues); } else { List issues = new ArrayList<>(); issues.addAll(makeIssue(IssueSeverity.ERROR, IssueType.NOTFOUND, path+".system", warningMessage)); diff --git a/org.hl7.fhir.utilities/src/main/resources/Messages.properties b/org.hl7.fhir.utilities/src/main/resources/Messages.properties index f39e1f169..335d99003 100644 --- a/org.hl7.fhir.utilities/src/main/resources/Messages.properties +++ b/org.hl7.fhir.utilities/src/main/resources/Messages.properties @@ -720,7 +720,7 @@ SD_VALUE_TYPE_IILEGAL = The element {0} has a {1} of type {2}, which is not in t SD_VALUE_TYPE_REPEAT_HINT = The repeating element has a {1}. The {1} will apply to all the repeats (this has not been clear to all users) 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 SD_NO_TYPES_OR_CONTENTREF = The element {0} has no assigned types, and no content reference -CODESYSTEM_CS_UNK_EXPANSION = The code provided ({2}) is not in the value set {0}, and a code is required from this value set. The system {1} is unknown. +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} is unknown. BUNDLE_SEARCH_NOSELF = SearchSet Bundles should have a self link that specifies what the search was BUNDLE_SEARCH_SELF_NOT_UNDERSTOOD = No types could be determined from the search string, so the types can''t be checked BUNDLE_SEARCH_ENTRY_NO_RESOURCE = SearchSet Bundle Entries must have resources