대시보드 에러처리 변경
This commit is contained in:
1 parent
f7dba437cf
commit
6301186288
2 files changed
+7
-1
No files matched your search
@@ -130,6 +130,9 @@ async def get_session() -> AsyncGenerator[AsyncSession, None]:
|
||||
try:
|
||||
yield session
|
||||
except Exception as e:
|
||||
from app.dashboard.exceptions import DashboardException
|
||||
if isinstance(e, DashboardException):
|
||||
raise e
|
||||
import traceback
|
||||
await session.rollback()
|
||||
logger.error(traceback.format_exc())
|
||||
|
||||
Reference in new issue
Block a user