diff --git a/src/pulp/solvers.py b/src/pulp/solvers.py index 5361288..22e55ce 100644 --- a/src/pulp/solvers.py +++ b/src/pulp/solvers.py @@ -463,7 +463,7 @@ class CPLEX_CMD(LpSolver_CMD): cplex = subprocess.Popen(self.path, stdin = subprocess.PIPE) cplex_cmds = "read "+tmpLp+"\n" if self.timelimit is not None: - cplex_cmds += "set timelimit " + self.timelimt + "\n" + cplex_cmds += "set timelimit " + str(self.timelimit) + "\n" for option in self.options: cplex_cmds += option+"\n" if lp.isMIP(): @@ -2523,4 +2523,4 @@ class GurobiFormulation(object): self.objective.name = name else: raise TypeError("Can only add LpConstraint, LpAffineExpression or True objects") - return self \ No newline at end of file + return self