Update Migrations to use the latest added columns

This commit is contained in:
Matthias 2021-08-03 10:25:59 +02:00 committed by GitHub
parent 5b6dbbd750
commit 07673ef47f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -171,7 +171,7 @@ def check_migrate(engine, decl_base, previous_tables) -> None:
table_back_name = get_backup_name(tabs, 'trades_bak')
# Check for latest column
if not has_column(cols, 'buy_tag'):
if not has_column(cols, 'is_short'):
logger.info(f'Running database migration for trades - backup: {table_back_name}')
migrate_trades_table(decl_base, inspector, engine, table_back_name, cols)
# Reread columns - the above recreated the table!