Skip to content

Commit 402784b

Browse files
committed
fixing bug in _load_slacks
1 parent 9fd504a commit 402784b

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

pyomo/solvers/plugins/solvers/xpress_direct.py

+2-4
Original file line numberDiff line numberDiff line change
@@ -1036,10 +1036,8 @@ def _load_slacks(self, cons_to_load=None):
10361036
if xpress_con in self._range_constraints:
10371037
## for xpress, the slack on a range constraint
10381038
## is based on the upper bound
1039-
## FIXME: This looks like a bug - there is no variable named
1040-
## `con` - there is, however, `xpress_con` and `pyomo_con`
1041-
lb = con.lb
1042-
ub = con.ub
1039+
lb = xpress_con.lb
1040+
ub = xpress_con.ub
10431041
ub_s = val
10441042
expr_val = ub - ub_s
10451043
lb_s = lb - expr_val

0 commit comments

Comments
 (0)