]> gitweb.michael.orlitzky.com - dunshire.git/blobdiff - src/dunshire/games.py
Print the game data along with every GameUnsolvableException.
[dunshire.git] / src / dunshire / games.py
index 43fa007c61077c90ef627e9738afbaa09dcde9c1..80f5f8ae2a46d09f15e34546c511edeca286f4fa 100644 (file)
@@ -445,7 +445,7 @@ class SymmetricLinearGame:
         # worst, since they indicate that CVXOPT is convinced the
         # problem is infeasible (and that cannot happen).
         if soln_dict['status'] in ['primal infeasible', 'dual infeasible']:
-            raise GameUnsolvableException(soln_dict)
+            raise GameUnsolvableException(self, soln_dict)
         elif soln_dict['status'] == 'unknown':
             # When we get a status of "unknown", we may still be able
             # to salvage a solution out of the returned
@@ -455,9 +455,9 @@ class SymmetricLinearGame:
             # primal/dual optimal solutions are within the cone (to a
             # tolerance as well).
             if abs(p1_value - p2_value) > options.ABS_TOL:
-                raise GameUnsolvableException(soln_dict)
+                raise GameUnsolvableException(self, soln_dict)
             if (p1_optimal not in self._K) or (p2_optimal not in self._K):
-                raise GameUnsolvableException(soln_dict)
+                raise GameUnsolvableException(self, soln_dict)
 
         return Solution(p1_value, p1_optimal, p2_optimal)