From 7c565cdaedf6e6caa36a1ee2f91af36d2091aa30 Mon Sep 17 00:00:00 2001 From: KeShih Date: Thu, 25 Jul 2024 21:22:27 +0800 Subject: [PATCH] Fix bugs in HiGHS termination status --- src/pyoptinterface/_src/highs.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pyoptinterface/_src/highs.py b/src/pyoptinterface/_src/highs.py index 5af00d6..1f92f52 100644 --- a/src/pyoptinterface/_src/highs.py +++ b/src/pyoptinterface/_src/highs.py @@ -194,7 +194,7 @@ def get_terminationstatus(model): elif model_status == Enum.kHighsModelStatusOptimal: return TerminationStatusCode.OPTIMAL elif model_status == Enum.kHighsModelStatusInfeasible: - return TerminationStatusCode.Infeasible + return TerminationStatusCode.INFEASIBLE elif model_status == Enum.kHighsModelStatusUnboundedOrInfeasible: return TerminationStatusCode.INFEASIBLE_OR_UNBOUNDED elif model_status == Enum.kHighsModelStatusUnbounded: @@ -206,7 +206,7 @@ def get_terminationstatus(model): elif model_status == Enum.kHighsModelStatusTimeLimit: return TerminationStatusCode.TIME_LIMIT elif model_status == Enum.kHighsModelStatusIterationLimit: - return TerminationStatusCode.IterationLimit + return TerminationStatusCode.ITERATION_LIMIT elif model_status == Enum.kHighsModelStatusUnknown: return TerminationStatusCode.OTHER_ERROR else: