From 26920c2af80fd73e2e44d786a795085a53dcab2c Mon Sep 17 00:00:00 2001 From: TehCupcakes Date: Wed, 7 Aug 2024 15:22:05 +0000 Subject: [PATCH] idac: Fix idac_round_info table migration (#21) This upgrade script was failing for people with an older db, due to the table not existing. Alternatively you could just remove the drop_table calls, but I assume they were put in place in case some users had an older version of the table schema, so this is a little safer. Reviewed-on: https://gitea.tendokyu.moe/Dniel97/artemis/pulls/21 Co-authored-by: TehCupcakes Co-committed-by: TehCupcakes --- .../versions/202d1ada1b39_idac_rounds_event_info_added.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/data/alembic/versions/202d1ada1b39_idac_rounds_event_info_added.py b/core/data/alembic/versions/202d1ada1b39_idac_rounds_event_info_added.py index 5868ecc..b792627 100644 --- a/core/data/alembic/versions/202d1ada1b39_idac_rounds_event_info_added.py +++ b/core/data/alembic/versions/202d1ada1b39_idac_rounds_event_info_added.py @@ -18,8 +18,8 @@ depends_on = None def upgrade(): - op.drop_table("idac_round_info") - op.drop_table("idac_user_round_info") + op.execute("DROP TABLE IF EXISTS idac_round_info") + op.execute("DROP TABLE IF EXISTS idac_user_round_info") op.create_table( "idac_round_info",