Skip to content

Commit ff46dd7

Browse files
committed
fix iis and test
1 parent 0a63048 commit ff46dd7

3 files changed

Lines changed: 3 additions & 3 deletions

File tree

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
### Fixed
77
- all fundamental callbacks now raise an error if not implemented
88
- Fixed the type of MatrixExpr.sum(axis=...) result from MatrixVariable to MatrixExpr.
9+
- Updated IIS result in PyiisfinderExec()
910
### Changed
1011
- changed default value of enablepricing flag to True
1112
### Removed

src/pyscipopt/iisfinder.pxi

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,4 +33,5 @@ cdef SCIP_RETCODE PyiisfinderExec (SCIP_IIS* iis, SCIP_IISFINDER* iisfinder, SCI
3333
PyIIS.iis._iis = iis
3434
result_dict = PyIIS.iisfinderexec()
3535
assert isinstance(result_dict, dict), "iisfinderexec() must return a dictionary."
36+
result[0] = result_dict.get("result", <SCIP_RESULT>result[0])
3637
return SCIP_OKAY

tests/test_iis.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -76,9 +76,7 @@ def test_iisGreddyMakeIrreducible():
7676
m.includeIISfinder(my_iis, "", "", priority=10000)
7777

7878
iis = m.generateIIS()
79-
with pytest.raises(AssertionError):
80-
assert not iis.isSubscipIrreducible() # this should not fail
81-
79+
assert not iis.isSubscipIrreducible()
8280
assert iis.isSubscipInfeasible()
8381

8482
iis.greedyMakeIrreducible()

0 commit comments

Comments
 (0)