diff --git a/open-reac/src/main/java/com/powsybl/openreac/parameters/input/OpenReacParameters.java b/open-reac/src/main/java/com/powsybl/openreac/parameters/input/OpenReacParameters.java index 62d3352a..f78f8155 100644 --- a/open-reac/src/main/java/com/powsybl/openreac/parameters/input/OpenReacParameters.java +++ b/open-reac/src/main/java/com/powsybl/openreac/parameters/input/OpenReacParameters.java @@ -594,14 +594,17 @@ private void checkLowAndHighVoltageLimitIntegrity(Network network, boolean integ .withUntypedValue("size", voltageLevelsWithMissingLimits.size()) .add(); voltageLevelsWithMissingLimits.forEach((key, value) -> { + String messageKey = "voltageLevelWithBothLimitsMissing"; String messageSuffix = "has undefined low and high voltage limits"; if (value.getLeft() == 0) { + messageKey = "voltageLevelWithUpperLimitMissing"; messageSuffix = "has undefined high voltage limit"; } else if (value.getRight() == 0) { + messageKey = "voltageLevelWithLowerLimitMissing"; messageSuffix = "has undefined low voltage limit"; } reportNode.newReportNode() - .withMessageTemplate("voltageLevelWithMissingLimits", "${vlId} " + messageSuffix) + .withMessageTemplate(messageKey, "${vlId} " + messageSuffix) .withSeverity(TypedValue.TRACE_SEVERITY) .withUntypedValue("vlId", key) .add();