mirror of
https://github.com/carrotquest/django-clickhouse.git
synced 2024-11-25 18:43:46 +03:00
Fixed error in migrate. Wrote tests
This commit is contained in:
parent
66ec7dd5db
commit
0268cc230a
|
@ -64,7 +64,7 @@ def migrate_app(app_label, db_alias, up_to=9999, database=None):
|
||||||
|
|
||||||
applied_migrations = database._get_applied_migrations(migrations_package)
|
applied_migrations = database._get_applied_migrations(migrations_package)
|
||||||
modules = import_submodules(migrations_package)
|
modules = import_submodules(migrations_package)
|
||||||
unapplied_migrations = set(modules.keys()) - applied_migrations
|
unapplied_migrations = set(modules.keys()) - set(applied_migrations)
|
||||||
|
|
||||||
for name in sorted(unapplied_migrations):
|
for name in sorted(unapplied_migrations):
|
||||||
print('Applying ClickHouse migration %s for app %s in database %s' % (name, app_label, db_alias))
|
print('Applying ClickHouse migration %s for app %s in database %s' % (name, app_label, db_alias))
|
||||||
|
|
Loading…
Reference in New Issue
Block a user