From 3e00faefdea3a284a4d5f627079b338310563774 Mon Sep 17 00:00:00 2001 From: Jennifer Taylor Date: Thu, 26 Sep 2024 01:21:17 +0000 Subject: [PATCH] Fix incompatibility with existing database migrator after SQLAlchemy 2.0. --- bemani/data/data.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bemani/data/data.py b/bemani/data/data.py index f926b10..7d96897 100644 --- a/bemani/data/data.py +++ b/bemani/data/data.py @@ -135,7 +135,7 @@ class Data: # See if the DB was already created try: cursor = self.__session.execute(text("SELECT COUNT(version_num) AS count FROM alembic_version")) - return cursor.fetchone()["count"] == 1 + return cursor.mappings().fetchone()["count"] == 1 except ProgrammingError: return False