[Frontend] Move engine/protocol.py out openai folder (#54492)

Signed-off-by: wang.yuqi <yuqi.wang@daocloud.io>
Signed-off-by: wang.yuqi <noooop@126.com>
Co-authored-by: Cyrus Leung <cyrus.tl.leung@gmail.com>
This commit is contained in:
wang.yuqi
2026-08-31 10:13:50 +00:00
committed by GitHub
co-authored by Cyrus Leung
parent d8de4ae322
commit eeb549a74d
194 changed files with 550 additions and 585 deletions
+9
View File
@@ -3,6 +3,7 @@
"""Custom exceptions for vLLM."""
from http import HTTPStatus
from typing import Any
@@ -116,3 +117,11 @@ class VLLMUnprocessableEntityError(VLLMClientError):
if self.value is not None:
extras.append(f"value={self.value}")
return f"{base} ({', '.join(extras)})" if extras else base
class GenerationError(VLLMServerError):
"""raised when finish_reason indicates internal server error (500)"""
def __init__(self, message: str = "Internal server error"):
super().__init__(message)
self.status_code = HTTPStatus.INTERNAL_SERVER_ERROR