2
0
mirror of https://github.com/m-labs/artiq.git synced 2024-12-26 03:38:25 +08:00

worker: Wait until datasets are written before quitting

Avoids a race condition in worker_impl.py where HDF5 dataset saving was
cut off before it finished for large datasets.
This commit is contained in:
Charles Baynham 2023-05-23 20:42:10 +01:00 committed by David Nadlinger
parent 58cc3b8d0a
commit c2b0c97640

View File

@ -347,12 +347,13 @@ def main():
elif action == "analyze":
try:
exp_inst.analyze()
put_completed()
finally:
# browser's analyze shouldn't write results,
# since it doesn't run the experiment and cannot have rid
if rid is not None:
write_results()
put_completed()
elif action == "examine":
examine(ExamineDeviceMgr, ExamineDatasetMgr, obj["file"])
put_completed()