Skip to content

Commit

Permalink
fix: schema error codes need to be JSON serializable
Browse files Browse the repository at this point in the history
[EC-680]
  • Loading branch information
jjaakola-aiven committed Dec 18, 2024
1 parent bcf9b36 commit f8a5096
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/schema_registry/routers/errors.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
See LICENSE for details
"""

from enum import Enum, unique
from enum import Enum, IntEnum, unique
from fastapi import HTTPException, status
from fastapi.exceptions import RequestValidationError


@unique
class SchemaErrorCodes(Enum):
class SchemaErrorCodes(IntEnum):
HTTP_BAD_REQUEST = status.HTTP_400_BAD_REQUEST
HTTP_NOT_FOUND = status.HTTP_404_NOT_FOUND
HTTP_CONFLICT = status.HTTP_409_CONFLICT
Expand Down

0 comments on commit f8a5096

Please sign in to comment.