master: record time run() is called

This commit is contained in:
Chris Ballance 2017-04-26 11:33:10 +01:00 committed by Sébastien Bourdeauducq
parent 0546affd4c
commit 8ebb33c05c
1 changed files with 3 additions and 0 deletions

View File

@ -223,6 +223,7 @@ def main():
ipc = pipe_ipc.ChildComm(sys.argv[1]) ipc = pipe_ipc.ChildComm(sys.argv[1])
start_time = None start_time = None
run_time = None
rid = None rid = None
expid = None expid = None
exp = None exp = None
@ -267,6 +268,7 @@ def main():
exp_inst.prepare() exp_inst.prepare()
put_object({"action": "completed"}) put_object({"action": "completed"})
elif action == "run": elif action == "run":
run_time = time.localtime()
exp_inst.run() exp_inst.run()
put_object({"action": "completed"}) put_object({"action": "completed"})
elif action == "analyze": elif action == "analyze":
@ -285,6 +287,7 @@ def main():
f["artiq_version"] = artiq_version f["artiq_version"] = artiq_version
f["rid"] = rid f["rid"] = rid
f["start_time"] = int(time.mktime(start_time)) f["start_time"] = int(time.mktime(start_time))
f["run_time"] = int(time.mktime(run_time))
f["expid"] = pyon.encode(expid) f["expid"] = pyon.encode(expid)
put_object({"action": "completed"}) put_object({"action": "completed"})
elif action == "examine": elif action == "examine":