Skip to content

Commit

Permalink
fix migration freezing
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisjsewell committed Jan 12, 2022
1 parent 95f80bb commit d522b44
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions aiida/backends/sqlalchemy/manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,9 @@ def migrate_down(self, version: str):
def _migrate_database_version(self):
"""Migrate the database to the latest schema version."""
super()._migrate_database_version()
transaction = get_scoped_session().get_transaction()
if transaction:
transaction.close()
self.migrate_up('head')


Expand Down

0 comments on commit d522b44

Please sign in to comment.