msg = "No traceName was specified"
self.error(msg)
- raise RuntimeError, msg
+ raise RuntimeError(msg)
self._store_path = self.ec.run_dir
try:
result = self.ec.trace(rm.guid, trace_name)
- f = open(fpath, "w")
- f.write(result)
- f.close()
+ with open(fpath, "w") as f:
+ f.write(result)
except:
import traceback
err = traceback.format_exc()