Skip to content

Commit acb105a

Browse files
committed
🐛 fix(alembic): incorrect change in 19aab8b
fix #12
1 parent ef116c4 commit acb105a

File tree

1 file changed

+3
-4
lines changed
  • nonebot_plugin_orm/templates/multidb

1 file changed

+3
-4
lines changed

nonebot_plugin_orm/templates/multidb/env.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
import asyncio
44
from typing import cast
5-
from contextlib import suppress
65

76
from alembic import context
87
from sqlalchemy.util import await_only
@@ -127,7 +126,7 @@ async def run_migrations_online() -> None:
127126
else:
128127
coro = run_migrations_online()
129128

130-
with suppress(RuntimeError):
129+
try:
131130
asyncio.run(coro)
132-
133-
await_only(coro)
131+
except RuntimeError:
132+
await_only(coro)

0 commit comments

Comments
 (0)