Skip to content

Commit

Permalink
Add python 3.13 compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
maxim-lixakov committed Dec 19, 2024
1 parent ea28d99 commit 7bcb1a2
Show file tree
Hide file tree
Showing 3 changed files with 368 additions and 182 deletions.
3 changes: 2 additions & 1 deletion horizon/backend/api/handlers.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

import http
import logging
from typing import Mapping

from asgi_correlation_id import correlation_id
from fastapi import HTTPException, Request, Response
Expand Down Expand Up @@ -115,7 +116,7 @@ def application_exception_handler(request: Request, exc: ApplicationError) -> Re
def exception_json_response(
status: int,
content: BaseErrorSchema,
headers: dict[str, str] | None = None,
headers: Mapping[str, str] | None = None,
) -> Response:
# Using Response + `model.json()` because JSONResponse + `model.dict()` does not convert Unset() to JSON value "<unset>"
content_type = type(content)
Expand Down
Loading

0 comments on commit 7bcb1a2

Please sign in to comment.