def kill_process ( process ) : logger = logging . getLogger ( 'xenon' ) logger . info ( 'Terminating Xenon-GRPC server.' ) os . kill ( process . pid , signal . SIGINT ) process . wait ( )
python kill process by inode
Kill the process group associated with the given process . ( posix )
def kill_process(process):
    """Kill the process group associated with the given process. (posix)"""
    logger = logging.getLogger('xenon')
    logger.info('Terminating Xenon-GRPC server.')
    os.kill(process.pid, signal.SIGINT)
    process.wait()