We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 03bdd65 commit 6c1d754Copy full SHA for 6c1d754
1 file changed
linopy/solvers.py
@@ -550,7 +550,7 @@ def solve_problem_from_file(
550
variables = {v.name for v in h.getVariables()}
551
552
def get_solver_solution() -> Solution:
553
- m = re.match(r"Optimal.* - objective value (\d+\.?\d*)$", first_line)
+ m = re.match(r"Optimal.* - objective value (-?\d+\.?\d*)$", first_line)
554
if m and len(m.groups()) == 1:
555
objective = float(m.group(1))
556
else:
0 commit comments