def run(self):
print("Building Solver ...")
self.build_solver()
- formulas = sorted(os.listdir(self.inputs.formulas.path), key=natural_key)
- shell.track(self.outputs.timing.path)
- for formula in formulas:
- print("Running for %s ..." % formula)
- try:
- self.run_solver(os.path.join(self.inputs.formulas.path, formula))
- except CommandFailed:
- break
+ with self.inputs.formulas as path:
+ formulas = sorted(os.listdir(path), key=natural_key)
+ shell.track(self.outputs.timing.path)
+
+ for formula in formulas:
+ print("Running for %s ..." % formula)
+ try:
+
+ self.run_solver(os.path.join(path, formula))
+ except CommandFailed:
+ break