1
0
mirror of https://github.com/janvarev/Irene-Voice-Assistant.git synced 2025-12-05 23:08:23 +02:00

Замена ручного указания ANSI Escape Codes на использование библиотеки termcolor

This commit is contained in:
modos189
2022-05-12 18:45:20 +03:00
parent cb665e8567
commit 2a88c0d9f2
2 changed files with 6 additions and 4 deletions

View File

@@ -3,6 +3,7 @@
from fastapi import FastAPI, HTTPException
import uvicorn
from multiprocessing import Process
from termcolor import cprint
#from pydantic import BaseModel
@@ -103,7 +104,7 @@ def core_update_timers_http(runReq=True):
@app.on_event("shutdown")
def app_shutdown():
global is_running
print("\033[93m{}\033[00m" .format("Ctrl-C pressed, exiting Irene."))
cprint("Ctrl-C pressed, exiting Irene.", "yellow")
is_running = False
if __name__ == "__main__":