Repository navigation
fix: reject vLLM previous_input_messages and enable_response_messages - #570
Merged
franciscojavierarceo merged 1 commit intoNov 19, 2026
Conversation
The gateway resolves previous_response_id and conversation history itself and forwarded these unmodeled vLLM extensions upstream. On Harmony models the supplied history was rendered on top of the resolved one, bypassing vLLM's previous_response_id exclusivity check; the requested upstream messages never reached the client. Reject them at admission in validate_modeled_extensions() with unsupported_parameter, accepting null, [] and false. Signed-off-by: Dong Wang <dongw2019@gmail.com>
sniper35
requested review from
bbrowning,
franciscojavierarceo,
haoshan98,
jiahuei,
leseb,
maralbahari,
noobHappylife,
qandrew and
tjtanaa
as code owners
November 19, 2026 07:09
franciscojavierarceo
approved these changes
Nov 19, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
A Responses request carrying vLLM's
previous_input_messagesextension was forwarded upstream after rehydration had already built the item history. On gpt-oss, vLLM rendered that history in front of the rehydrated one: aprevious_response_idturn with a contradictoryprevious_input_messageswent from 177 to 204 input tokens and still returned 200. Sent directly, vLLM rejects that combination, but behind the gateway it never seesprevious_response_id.enable_response_messages: truewas also forwarded, and the requestedinput_messages/output_messagesnever reached the client. Both are now rejected at admission invalidate_modeled_extensions(), next to thetop_logprobscheck. Fixes #571; refs #314, vllm-project/vllm#68575.Changes by API
/v1/responses, HTTP JSON/SSE and WebSocket, split-execution hydration)previous_input_messagesandenable_response_messages: truereturn400 invalid_request_error,code: "unsupported_parameter", with the member asparam. Absent,null,[]andfalseare still accepted.Test Plan
backgroundandprompt.test_unsupported_parameters_are_rejected_for_both_store_values(HTTP envelope,store×stream),websocket_rejects_unsupported_parameters_and_keeps_the_connection,unsupported_parameters_test(executor in both stream modes with no upstream call, andrehydrate_conversation), and theunsupported.rsunit tests (param/code;null/[]/falseaccepted).cargo fmt --all -- --checkandcargo clippy --workspace --all-targets -- -D warnings: pass.cargo test --workspace --no-fail-fast: 3222 passed, 4 failed, 25 ignored;main(8c1cd74) on the same runner: 3219 passed, 6 failed, 25 ignored. All failures on both areexecutor::inference::tests::error_bodies::streaming_error_timeout_*idle-timeout tests (the branch's 4 are a subset of main's 6); run alone, they pass on both.pre-commit run --all-filesandmkdocs build: pass.This touches the same rejection-test arrays and docs section as #496; I'll rebase whichever lands second.
AI assistance was used for the analysis and the test harness; I reviewed the change and the results.