Skip to content

Commit 9081099

Browse files
authored
Merge pull request #1376 from tisnik/lcore-1273-replaced-http-status-code
LCORE-1273: Replaced HTTP status code
2 parents 84a81d1 + ecd993a commit 9081099

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/models/responses.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2217,7 +2217,7 @@ def __init__(
22172217
super().__init__(
22182218
response=response,
22192219
cause=cause,
2220-
status_code=status.HTTP_413_REQUEST_ENTITY_TOO_LARGE,
2220+
status_code=status.HTTP_413_CONTENT_TOO_LARGE,
22212221
)
22222222

22232223

tests/unit/models/responses/test_error_responses.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -687,7 +687,7 @@ def test_constructor_with_default_response(self) -> None:
687687
cause="The prompt exceeds the maximum allowed length."
688688
)
689689
assert isinstance(response, AbstractErrorResponse)
690-
assert response.status_code == status.HTTP_413_REQUEST_ENTITY_TOO_LARGE
690+
assert response.status_code == status.HTTP_413_CONTENT_TOO_LARGE
691691
assert isinstance(response.detail, DetailModel)
692692
assert response.detail.response == "Prompt is too long"
693693
assert response.detail.cause == "The prompt exceeds the maximum allowed length."

0 commit comments

Comments
 (0)