Example #1
0
def kill(pid: int):
    """Terminate a running process"""
    os.kill(pid, signal.SIGSTOP)
    log.info('Kill process {0}'.format(pid))
Example #2
0
def sleep(pid: int):
    """Tell a process to sleep"""
    os.waitpid(pid, os.WSTOPPED)
    log.info('Wait process {0}'.format(pid))
Example #3
0
def wake(pid: int):
    """Continue a stopped process"""
    os.kill(pid, signal.SIGCONT)
    log.info('Continue process {0}'.format(pid))
Example #4
0
File: Bot.py Project: ptdel/Rekt
async def on_ready():
    logging.info(f"Online : {datetime.now().isoformat()}")
Example #5
0
File: Bot.py Project: ptdel/Rekt
async def on_message_edit(before, after):
    logging.info(f"Changed : {before} -> {after}")
Example #6
0
File: Bot.py Project: ptdel/Rekt
async def on_message_delete(message):
    logging.info(f"Deleted : {message}")
Example #7
0
File: Bot.py Project: ptdel/Rekt
async def on_message(message):
    checkedMessage = CheckedMessage(message)
    logging.info(checkedMessage())
Example #8
0
File: Bot.py Project: ptdel/Rekt
async def on_resumed():
    logging.info(f"Resumed : {datetime.now().isoformat()}")