We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 36e1411 commit 591e0aaCopy full SHA for 591e0aa
1 file changed
packages/derisk-core/src/derisk/storage/metadata/db_manager.py
@@ -401,6 +401,12 @@ def init_db(
401
if async_url.startswith("mysql+ob://"):
402
# 替换为asyncmy驱动
403
async_url = async_url.replace("mysql+ob://", "mysql+asyncmy://")
404
+ elif async_url.startswith("mysql+pymysql://"):
405
+ # 替换为asyncmy驱动(标准MySQL异步驱动)
406
+ async_url = async_url.replace("mysql+pymysql://", "mysql+asyncmy://")
407
+ elif async_url.startswith("mysql://"):
408
+ # 纯mysql://也替换为asyncmy
409
+ async_url = async_url.replace("mysql://", "mysql+asyncmy://")
410
if async_url.startswith("sqlite"):
411
# Don't upgrade memory db to async sqlite in tests, it fails with sync engine
412
# unless we know for sure it's not a test using sync engine
0 commit comments