runmanager.compile_labscript_with_globals_files_async

runmanager.compile_labscript_with_globals_files_async(labscript_file, globals_files, output_path, stream_port, done_callback)[source]

Compiles labscript_file with multiple globals files into a directory.

Instead, stderr and stdout will be put to stream_port via zmq push in the multipart message format ['stdout','hello, worldn'] etc. When compilation is finished, the function done_callback will be called a boolean argument indicating success or failure. If you want to receive the data on a zmq socket, do so using a PULL socket created from a labscript_utils.ls_zprocess.Context, or using a labscript_utils.ls_zprocess.ZMQServer. These subclasses will also be configured with the appropriate security settings and will be able to receive the messages.

Parameters:
  • labscript_file (str) – Path to labscript file to be compiled

  • globals_files (list of str) – Paths to h5 file where globals values to be used are stored. See make_run_file_from_globals_files() for details.

  • output_path (str) – Folder to save compiled h5 files to.

  • stream_port (zmq.socket) – ZMQ socket to push stdout and stderr.

  • done_callback (function) – Callback function run when compilation finishes. Takes a single boolean argument marking compilation success or failure.