Skip to content

[Misc] Align error handling with upstream vLLM v0.14.0#1122

Merged
hsliuustc0106 merged 2 commits intovllm-project:mainfrom
ceanna93:refactor/remove-validation-error-todo
Feb 1, 2026
Merged

[Misc] Align error handling with upstream vLLM v0.14.0#1122
hsliuustc0106 merged 2 commits intovllm-project:mainfrom
ceanna93:refactor/remove-validation-error-todo

Conversation

@ceanna93
Copy link
Contributor

PLEASE FILL IN THE PR DESCRIPTION HERE ENSURING ALL CHECKLIST ITEMS (AT THE BOTTOM) HAVE BEEN CONSIDERED.

Purpose

Align error handling with upstream vLLM v0.14.0.

When vLLM was updated to v0.14.0 in #878, corresponding error handling improvements were not applied to OmniOpenAIServingChat. This PR completes the synchronization by:

  • Removing outdated TODO comments (4 locations)
  • Passing exception objects directly to error handlers (str(e)e)

Test Plan

Start vllm-omni server and send validation error requests:

# Start server
vllm serve <model-path> --omni --port 8000

# Test with invalid request
curl http://localhost:8000/v1/chat/completions \
  -H "Content-Type: application/json" \
  -d '{
    "model": "Z-Image-Turbo",
    "messages": []
}'

Test Result

Error responses are properly formatted with correct HTTP status codes:

{
    "error": {
        "message": "No text prompt found in messages",
        "type": "BadRequestError",
        "param": null,
          "code": 400
    }
}

Essential Elements of an Effective PR Description Checklist
  • The purpose of the PR, such as "Fix some issue (link existing issues this PR will resolve)".
  • The test plan, such as providing test command.
  • The test results, such as pasting the results comparison before and after, or e2e results
  • (Optional) The necessary documentation update, such as updating supported_models.md and examples for a new model.
  • (Optional) Release notes update. If your change is user facing, please update the release notes draft.

BEFORE SUBMITTING, PLEASE READ https://github.com/vllm-project/vllm-omni/blob/main/CONTRIBUTING.md (anything written below this line will be removed by GitHub Actions)

  - Remove TODO comments about vllm-specific validation errors
  - Pass exception objects directly to error response methods (str(e) -> e)
  - Ensures proper error response formatting with vLLM v0.14.0

Signed-off-by: anna <[email protected]>
@hsliuustc0106 hsliuustc0106 added the ready label to trigger buildkite CI label Jan 31, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR aligns error handling with upstream vLLM v0.14.0 by removing outdated TODO comments and passing exception objects directly to error handlers instead of converting them to strings first.

Changes:

  • Removed 4 TODO comments about vLLM-specific validation errors
  • Updated error handlers to pass exception objects directly (e instead of str(e))

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

except ValueError as e:
# TODO: Use a vllm-specific Validation Error
return self.create_error_response(str(e))
return self.create_error_response(e)
Copy link

Copilot AI Jan 31, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Inconsistent error handling: While this PR updates some error handlers to pass exception objects directly (lines 289, 317, 1287, 1312), there are similar error handlers in the same file that still use str(e):

  • Line 634: self.create_streaming_error_response(str(e)) for RuntimeError
  • Line 646: self.create_streaming_error_response(str(e)) for Exception
  • Line 1485: self.create_error_response(str(e)) for RuntimeError
  • Line 1570: self.create_error_response(str(e)) for RuntimeError

For consistency with the upstream vLLM v0.14.0 alignment mentioned in the PR description, these should also be updated to pass the exception object directly (removing str() wrapper).

Copilot uses AI. Check for mistakes.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

@ceanna93 ceanna93 Feb 1, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@hsliuustc0106 Thanks for letting me know! I've updated the remaining call sites. a85dad9

Update remaining callers to pass exception objects directly instead of converting to string, consistent with the updated function signatures.

Signed-off-by: anna <[email protected]>
@ceanna93 ceanna93 force-pushed the refactor/remove-validation-error-todo branch from f897f30 to a85dad9 Compare February 1, 2026 07:03
@tzhouam tzhouam requested a review from Copilot February 1, 2026 07:31
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@tzhouam
Copy link
Collaborator

tzhouam commented Feb 1, 2026

LGTM

@hsliuustc0106 hsliuustc0106 merged commit df3b347 into vllm-project:main Feb 1, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready label to trigger buildkite CI

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants