Skip to content

Commit db80ff9

Browse files
authored
Merge pull request Pyomo#3509 from mrmundt/highspy-patch
BUGFIX: Add logic for highspy versions
2 parents 1b18e2e + face620 commit db80ff9

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Diff for: pyomo/contrib/appsi/solvers/highs.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,8 @@ def _solve(self, timer: HierarchicalTimer):
273273
self._warm_start()
274274
timer.start('optimize')
275275
ostreams[-1].write("RUN!\n")
276-
self._solver_model.HandleKeyboardInterrupt = True
276+
if self.version()[0] >= 1 and self.version()[1] >= 8:
277+
self._solver_model.HandleKeyboardInterrupt = True
277278
self._solver_model.run()
278279
timer.stop('optimize')
279280

0 commit comments

Comments
 (0)