ignore UserWarning; ignore flaskwebgui log

This commit is contained in:
Qing
2022-10-24 18:29:33 +08:00
parent b00af182de
commit 476159bbe5
2 changed files with 4 additions and 2 deletions

View File

@@ -57,7 +57,7 @@ BUILD_DIR = os.environ.get("LAMA_CLEANER_BUILD_DIR", "app/build")
class NoFlaskwebgui(logging.Filter):
def filter(self, record):
return "GET //flaskwebgui-keep-server-alive" not in record.getMessage()
return "GET /flaskwebgui-keep-server-alive" not in record.getMessage()
logging.getLogger("werkzeug").addFilter(NoFlaskwebgui())