대시보드 기능 추가

This commit is contained in:
skkim committed 2026-02-24 15:23:11 +09:00
1 parent 1398546dac
commit b0cebb97ef
22 files changed
+2700 -1

No files matched your search

+14
View File
@@ -309,6 +309,20 @@ def add_exception_handlers(app: FastAPI):
content=content,
)
# DashboardException 핸들러 추가
from app.dashboard.exceptions import DashboardException
@app.exception_handler(DashboardException)
def dashboard_exception_handler(request: Request, exc: DashboardException) -> Response:
logger.debug(f"Handled DashboardException: {exc.__class__.__name__} - {exc.message}")
return JSONResponse(
status_code=exc.status_code,
content={
"detail": exc.message,
"code": exc.code,
},
)
@app.exception_handler(status.HTTP_500_INTERNAL_SERVER_ERROR)
def internal_server_error_handler(request, exception):
# 에러 메시지 로깅 (한글 포함 가능)