simonsobs / sorunlib

High level library for running observatory operations using OCS.
BSD 2-Clause "Simplified" License
0 stars 0 forks source link

Create blocking process monitor function #123

Closed BrianJKoopman closed 10 months ago

BrianJKoopman commented 10 months ago

This PR introduces monitor_process(), a function that replaces the use of run.commands.wait_until within seq.scan. It accomplishes the same effect as wait_until -- blocking until the specified time -- and also continuously checks the status of a given process ('generate_scan', in the seq.scan case.) It'll raise an exception if the process fails, ending the current schedule.

This can generally be used on any process, however since it is blocking it can't monitor processes that need to run during a scan.

Resolves #115. Resolves #113.