logging improvements (#2073)

* Scheduled tasks log to Debug, not Info

* Add LOG_LEVEL config to .env

* Update some other log levels and fix typos

* fix logger initializer

---------

Co-authored-by: Jakob Rubin <647846+Grygon@users.noreply.github.com>
This commit is contained in:
Hayden
2023-01-28 16:54:44 -09:00
committed by GitHub
parent 9ddb27b2e3
commit 530f7c9d6b
13 changed files with 28 additions and 24 deletions

View File

@@ -87,7 +87,7 @@ def main():
alembic_cfg = Config(str(PROJECT_DIR / "alembic.ini"))
if db_is_at_head(alembic_cfg):
logger.info("Migration not needed.")
logger.debug("Migration not needed.")
else:
logger.info("Migration needed. Performing migration...")
command.upgrade(alembic_cfg, "head")
@@ -95,7 +95,7 @@ def main():
db = get_repositories(session)
if db.users.get_all():
logger.info("Database exists")
logger.debug("Database exists")
else:
logger.info("Database contains no users, initializing...")
init_db(db)