From 38a10c6c1666e7f6e77ce2648f94bfd3875128d5 Mon Sep 17 00:00:00 2001 From: Kou Oishi Date: Tue, 23 Jun 2026 11:25:26 +0900 Subject: [PATCH 1/2] Modify MySQL_NoAsync.py: this was missing in the last PR for MySQL.py --- app/plugin/datasource_MySQL_NoAsync.py | 3 ++- app/server/sd_version.py | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/app/plugin/datasource_MySQL_NoAsync.py b/app/plugin/datasource_MySQL_NoAsync.py index 30bddaab..8de15a67 100644 --- a/app/plugin/datasource_MySQL_NoAsync.py +++ b/app/plugin/datasource_MySQL_NoAsync.py @@ -39,7 +39,8 @@ async def connect(self): try: conn = mysql.connect( host=self.host, port=self.port, user=self.user, - password=self.password, database=self.database + password=self.password, database=self.database, + autocommit=True ) except Exception as e: logging.error("MySQL: %s: %s" % (self.url, str(e))) diff --git a/app/server/sd_version.py b/app/server/sd_version.py index aefd2e69..27934477 100644 --- a/app/server/sd_version.py +++ b/app/server/sd_version.py @@ -1 +1 @@ -slowdash_version = '260602 "Stawamus"' +slowdash_version = '260623 "Stawamus"' From 3abb2b9372242f3b9e21d7547c76f3b73218c678 Mon Sep 17 00:00:00 2001 From: Kou Oishi Date: Tue, 23 Jun 2026 11:57:49 +0900 Subject: [PATCH 2/2] Modify MySQL.py: make it consistent with the last commit. --- app/plugin/datasource_MySQL.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/app/plugin/datasource_MySQL.py b/app/plugin/datasource_MySQL.py index 8a13f2ea..b098d825 100644 --- a/app/plugin/datasource_MySQL.py +++ b/app/plugin/datasource_MySQL.py @@ -58,7 +58,6 @@ async def execute(self, sql, params=()): async with self.pool.acquire() as conn: async with conn.cursor() as cursor: await cursor.execute(sql, params) - await conn.commit() except Exception as e: if not self.connection_error_reported: logging.error(f'MySQL Async Execute Error: {e}') @@ -81,7 +80,6 @@ async def fetch(self, sql, params=()): async with self.pool.acquire() as conn: async with conn.cursor(aiomysql.DictCursor) as cursor: await cursor.execute(sql, params) - await conn.commit() rows = await cursor.fetchall() except Exception as e: if not self.connection_error_reported: @@ -124,7 +122,8 @@ async def connect(self): try: pool = await aiomysql.create_pool( - host=self.host, port=self.port, user=self.user, password=self.password, db=self.database + host=self.host, port=self.port, user=self.user, password=self.password, db=self.database, + autocommit=True ) except Exception as e: logging.error(f'AsyncMySQL: {self.url}: {e}')