Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
OpenDAS
vllm_cscc
Commits
f7197722
Unverified
Commit
f7197722
authored
Jun 28, 2025
by
Michael Goin
Committed by
GitHub
Jun 27, 2025
Browse files
[Bugfix] Properly reject requests with empty list guided_choice (#20195)
Signed-off-by:
mgoin
<
mgoin64@gmail.com
>
parent
d45417b8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
0 deletions
+6
-0
vllm/v1/engine/processor.py
vllm/v1/engine/processor.py
+6
-0
No files found.
vllm/v1/engine/processor.py
View file @
f7197722
...
@@ -173,6 +173,12 @@ class Processor:
...
@@ -173,6 +173,12 @@ class Processor:
params
.
guided_decoding
.
backend
=
engine_level_backend
params
.
guided_decoding
.
backend
=
engine_level_backend
# Request content validation
# Request content validation
if
(
isinstance
(
params
.
guided_decoding
.
choice
,
list
)
and
not
params
.
guided_decoding
.
choice
):
# It is invalid for choice to be an empty list
raise
ValueError
(
f
"Choice '
{
params
.
guided_decoding
.
choice
}
' "
"cannot be an empty list"
)
if
engine_level_backend
.
startswith
(
"xgrammar"
):
if
engine_level_backend
.
startswith
(
"xgrammar"
):
# xgrammar with no fallback
# xgrammar with no fallback
validate_xgrammar_grammar
(
params
)
validate_xgrammar_grammar
(
params
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment