hpcflow.sdk.helper.helper.kill_proc_tree#
- hpcflow.sdk.helper.helper.kill_proc_tree(pid, sig=Signals.SIGTERM, include_parent=True, timeout=None, on_terminate=None)#
Kill a process tree (including grandchildren) with signal sig and return a (gone, still_alive) tuple. on_terminate, if specified, is a callback function which is called as soon as a child terminates.
- Returns:
list[Process] – The process and subprocesses that have died.
list[Process] – The process and subprocesses that are still alive.
- Parameters:
- Return type: