Skip to content

Commit

Permalink
remove the prints. Show available solvers
Browse files Browse the repository at this point in the history
  • Loading branch information
pchtsp committed Jul 11, 2024
1 parent e30f027 commit a96fae6
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 74 deletions.
4 changes: 3 additions & 1 deletion pulp/apis/coin_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -182,8 +182,10 @@ def solve_CBC(self, lp, use_mps=True):
"Pulp: Error while trying to execute, use msg=True for more details"
+ self.path
)
if pipe:
try:
pipe.close()
except:
pass
if not os.path.exists(tmpSol):
raise PulpSolverError("Pulp: Error while executing " + self.path)
(
Expand Down
4 changes: 4 additions & 0 deletions pulp/tests/run_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@


def pulpTestAll(test_docs=False):
all_solvers = pulp.listSolvers(onlyAvailable=False)
available = pulp.listSolvers(onlyAvailable=True)
print(f"Available solvers: {available}")
print(f"Unavailable solvers: {set(all_solvers) - set(available)}")
runner = unittest.TextTestRunner()
suite_all = get_test_suite(test_docs)
# we run all tests at the same time
Expand Down
Loading

0 comments on commit a96fae6

Please sign in to comment.