From fa50123d3bb47f62c4c37766cdb4d941014763cc Mon Sep 17 00:00:00 2001 From: Sven Heidemann Date: Sun, 2 Oct 2022 13:22:41 +0200 Subject: [PATCH] Improved logging for migrations #45 --- src/bot_data/service/migration_service.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/bot_data/service/migration_service.py b/src/bot_data/service/migration_service.py index fef42f2165..fc2d5913f6 100644 --- a/src/bot_data/service/migration_service.py +++ b/src/bot_data/service/migration_service.py @@ -31,11 +31,10 @@ class MigrationService: # there is a table named "tableName" self._logger.trace(__name__, f"Running SQL Command: {MigrationHistory.get_select_by_id_string(migration_id)}") migration_from_db = self._db.select(MigrationHistory.get_select_by_id_string(migration_id)) - self._logger.trace(__name__, str(migration_from_db)) if migration_from_db is not None and len(migration_from_db) > 0: continue - self._logger.debug(__name__, f"Running Migration {migration}") + self._logger.debug(__name__, f"Running Migration {migration_id}") migration_as_service: MigrationABC = self._services.get_service(migration) migration_as_service.upgrade() self._cursor.execute(MigrationHistory(migration_id).insert_string)