[Misc] Use VLLMValidationError in offline inference input validation (#53432)

Signed-off-by: Jensen Chen <a1043904820@gmail.com>
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
Jensen Chen
2026-08-23 08:43:51 -07:00
committed by GitHub
co-authored by Claude Opus 5
parent b26039b09f
commit 39eba6ac36
4 changed files with 67 additions and 7 deletions
+2 -1
View File
@@ -12,6 +12,7 @@ import pytest
from tests.utils import multi_gpu_test
from vllm import LLM, SamplingParams
from vllm.exceptions import VLLMValidationError
from vllm.lora.request import LoRARequest
MODEL_PATH = "Qwen/Qwen3-0.6B"
@@ -192,7 +193,7 @@ def test_multiple_lora_requests():
assert len(PROMPTS) == len(outputs)
# Exception raised, if the size of params does not match the size of prompts
with pytest.raises(ValueError):
with pytest.raises(VLLMValidationError):
outputs = llm.generate(PROMPTS, lora_request=lora_request[:1])
# Single LoRARequest should be applied to every prompt