From d60acd169b0602722b69455ed8b808c21d7110f3 Mon Sep 17 00:00:00 2001 From: Michael Weimann Date: Mon, 28 Feb 2022 18:48:32 +0100 Subject: [PATCH] fix code style --- app.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app.py b/app.py index 657ded5..cd61a68 100644 --- a/app.py +++ b/app.py @@ -10,7 +10,6 @@ from flask import Flask from flask_cors import CORS from flask_migrate import Migrate from flask_sqlalchemy import SQLAlchemy -from ldap3.utils.log import logger as ldap3_logger from ldap3.utils.log import set_library_log_detail_level, BASIC load_dotenv(find_dotenv()) @@ -21,10 +20,11 @@ app = Flask(__name__) loglevel = os.getenv("KI_LOGLEVEL", logging.WARNING) loglevel = int(loglevel) app.logger.setLevel(loglevel) -app.logger.propagate = False # do not forward messages to the root logger -logging.basicConfig(level=loglevel, format='[%(asctime)s] %(levelname)s [%(name)s] %(message)s') # configure root logger as fallback -logging.getLogger('werkzeug').propagate = False # werkzeug has its own ColorStreamHandler -set_library_log_detail_level(BASIC) # ldap3 has different verbosity levels internally +app.logger.propagate = False # do not forward messages to the root logger +logging.basicConfig(level=loglevel, + format='[%(asctime)s] %(levelname)s [%(name)s] %(message)s') # configure root logger as fallback +logging.getLogger('werkzeug').propagate = False # werkzeug has its own ColorStreamHandler +set_library_log_detail_level(BASIC) # ldap3 has different verbosity levels internally app.config["SQLALCHEMY_DATABASE_URI"] = os.getenv("SQLALCHEMY_DATABASE_URI") app.config["SQLALCHEMY_TRACK_MODIFICATIONS"] = False