Skip to content

Commit 2bc148e

Browse files
authored
Fix solution printing when problem is unsolvable (#25)
This is a followup from #21
1 parent 6b44ea6 commit 2bc148e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

autoparallel/optimize_sharding.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -410,7 +410,7 @@ def get_solution(self, verbose=False):
410410
self.res = [k for k, v in sol.items() if v == 1]
411411

412412
if self.prob.status == -1:
413-
self.print()
413+
print(self.get_log())
414414
raise RuntimeError("Unsolvable problem")
415415

416416
opt = {}

0 commit comments

Comments
 (0)