Description
Original report (archived issue) by Philip Starkey (Bitbucket: pstarkey, GitHub: philipstarkey).
runmanager sequentially instructs the batch compiler to compile each shot in a sequence and sends the labscript file path and the HDF5 file path to the batch compiler process.
Because only the path to the labscript file is passed, if a user modifies and saves the labscript file during the compilation, then some shots will use the old labscript file, and some will use the new labscript file, rendering the results of the sequence meaningless.
I think in order to protect against this we need to:
- cache a copy of the labscript file rather than exec-ing the file itself
- Use module watcher to detect changes to modules used by the labscript file and abort a compilation sequence if anything changes.
Alternatively, if #47 was implemented, we might be able to solve point 2 above by holding the module watcher lock across the compilation of all shots.
Note: There may be other corner cases I've missed in this analysis.