forked from openlp/openlp
Close session after upgrade. Fixes a filelock issue in windows tests.
This commit is contained in:
parent
38db55a37c
commit
cffad28749
@ -156,7 +156,10 @@ def upgrade_db(url, upgrade):
|
|||||||
except (SQLAlchemyError, DBAPIError):
|
except (SQLAlchemyError, DBAPIError):
|
||||||
version_meta = Metadata.populate(key='version', value=int(upgrade.__version__))
|
version_meta = Metadata.populate(key='version', value=int(upgrade.__version__))
|
||||||
session.commit()
|
session.commit()
|
||||||
return int(version_meta.value), upgrade.__version__
|
upgrade_version = upgrade.__version__
|
||||||
|
version_meta = int(version_meta.value)
|
||||||
|
session.close()
|
||||||
|
return version_meta, upgrade_version
|
||||||
|
|
||||||
|
|
||||||
def delete_database(plugin_name, db_file_name=None):
|
def delete_database(plugin_name, db_file_name=None):
|
||||||
|
Loading…
Reference in New Issue
Block a user