There is no need to remove output file as it gets rewritten by
open(self.eventfile, 'w') anyway.
Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
self.event_queue = []
def init_file(self):
- try:
- # delete the old log
- os.remove(self.eventfile)
- except:
- pass
-
# write current configuration data
with open(eventfile, "w") as f:
f.write("%s\n" % json.dumps({ "allvariables" : self.cooker.getAllKeysWithFlags(["doc", "func"])}))