Skip to content

fix(vllm): align vLLM-Omni pin with bundled vLLM 0.24.0 - #11345

Closed
tanmayv25 wants to merge 6 commits into
mainfrom
tanmayv/fix-vllm-omni-version-mismatch
Closed

fix(vllm): align vLLM-Omni pin with bundled vLLM 0.24.0#11345
tanmayv25 wants to merge 6 commits into
mainfrom
tanmayv/fix-vllm-omni-version-mismatch

Conversation

@tanmayv25

@tanmayv25 tanmayv25 commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Overview

The vllm-runtime image bundles vLLM 0.24.0 but container/context.yaml pinned vllm_omni_ref to v0.23.0rc1. vLLM-Omni is built against a specific vLLM release line and imports internal vLLM symbols (e.g. split_routed_experts) that are added/renamed/removed across releases. A major/minor skew therefore crashes at import time with an opaque ImportError, before the unified-omni worker can register — so the Frontend's /v1/models stays permanently empty and no image/video/audio request is ever served.

This is the same class of failure originally reported against 1.3.0-rc.2 (omni 0.21.x vs vLLM 0.23.0); on main it re-appeared as omni 0.23.x vs vLLM 0.24.0.

Fix

  • Bump vllm_omni_ref to v0.24.0 (the vLLM-Omni build aligned with upstream vLLM 0.24.0) in container/context.yaml.
  • Refresh the stale version reference comment in container/deps/vllm/protected_packages.txt.

Note: vLLM-Omni releases can lag vLLM, so the refs are aligned manually per release rather than enforced in lockstep.

Test

Rebuilt the vllm-runtime image (x86_64) with the aligned pin and ran the aggregated omni worker:

  • from dynamo.vllm.unified_omni import VllmOmniEngine imports cleanly (previously crashed on split_routed_experts).
  • The omni worker starts and registers; the Frontend's /v1/models is populated.
  • End-to-end POST /v1/videos with Wan-AI/Wan2.1-T2V-1.3B-Diffusers returns status: "completed" and writes a valid H.264 MP4.

A rebuild of the vllm-runtime image is required for the pin change to take effect.

…match

The vllm-runtime image bundles vLLM 0.24.0 but vllm_omni_ref was still
pinned to v0.23.0rc1. vLLM-Omni imports internal vLLM symbols (e.g.
split_routed_experts) that change across releases, so a major/minor skew
crashes at import time with an opaque ImportError. The unified-omni worker
then never registers and the Frontend's /v1/models stays empty.

- Bump vllm_omni_ref to v0.24.0 (aligned with bundled vLLM 0.24.0).
- Add a fail-fast guard (check_vllm_omni_compatibility) that raises an
  actionable OmniVersionMismatchError on a major/minor mismatch.
- Add regression tests for the guard.
- Refresh the stale version reference in protected_packages.txt.

Signed-off-by: tanmayv25 <tanmayv@nvidia.com>
@tanmayv25
tanmayv25 requested a review from a team as a code owner July 7, 2026 18:55
@tanmayv25
tanmayv25 requested a review from a team July 7, 2026 18:55
@tanmayv25
tanmayv25 requested review from a team as code owners July 7, 2026 18:55
@copy-pr-bot

copy-pr-bot Bot commented Jul 7, 2026

Copy link
Copy Markdown

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

@datadog-official

This comment has been minimized.

@coderabbitai

coderabbitai Bot commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Walkthrough

Adds a version_check.py module implementing a fail-fast compatibility check between installed vllm and vllm-omni package versions, wires it into module import in omni/__init__.py, adds corresponding unit tests, and bumps the bundled vllm-omni reference version in container configuration files.

Changes

Version compatibility guard

Layer / File(s) Summary
Compatibility check implementation
components/src/dynamo/vllm/omni/version_check.py
Adds OmniVersionMismatchError and check_vllm_omni_compatibility(), which parses installed vllm/vllm-omni versions via importlib.metadata, skips on unparseable/missing metadata, and raises on major/minor mismatch.
Wire check into package import
components/src/dynamo/vllm/omni/__init__.py
Calls the compatibility check at import time before importing handler classes, with # noqa: E402 comments to allow the reordered imports.
Compatibility check tests
components/src/dynamo/vllm/tests/omni/test_omni_version_check.py
New pytest module testing version parsing edge cases, mismatch error raising with version details in the message, aligned-version success, and behavior when package metadata lookup fails.
Bundled vllm-omni version update
container/context.yaml, container/deps/vllm/protected_packages.txt
Bumps vllm_omni_ref from v0.23.0rc1 to v0.24.0 with added version-matching comments, and updates the safetensors requirement comment to reference v0.24.0.

Estimated code review effort: 2 (Simple) | ~12 minutes

Suggested labels: vllm, tests, container

Suggested reviewers: dynamo vLLM maintainers

🐰 A version check hops in with care,
Comparing vLLM pairs to spare,
If numbers clash, it won't proceed,
It logs, it guards, then plants the seed,
Of v0.24.0 everywhere!

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description covers the overview, fix, and test, but it omits the required Details, reviewer start point, and Related Issues sections. Add the missing template sections: Details, Where should reviewer start?, and Related Issues with either a linked issue or the no-issue confirmation.
✅ Passed checks (4 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title is concise and accurately summarizes the main change: aligning the vLLM-Omni pin with bundled vLLM 0.24.0.

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🧹 Nitpick comments (1)
components/src/dynamo/vllm/tests/omni/test_omni_version_check.py (1)

66-72: 🎯 Functional Correctness | 🔵 Trivial | ⚡ Quick win

Simulate the real exception type for the missing-metadata case.

This test raises a generic Exception to simulate missing metadata, but importlib.metadata.version() actually raises importlib.metadata.PackageNotFoundError for a missing package. If the broad except Exception in version_check.py is narrowed to catch PackageNotFoundError (recommended in that file's review), this test would start failing with an unhandled exception instead of exercising the skip path.

🔧 Proposed fix
 def test_missing_metadata_is_skipped():
     def _raise(name):
-        raise Exception("no metadata")
+        raise importlib.metadata.PackageNotFoundError(name)
 
     with patch("importlib.metadata.version", _raise):
         # Should not raise; downstream import handles the missing package.
         check_vllm_omni_compatibility()

(requires import importlib.metadata at the top of this test module)

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@components/src/dynamo/vllm/tests/omni/test_omni_version_check.py` around
lines 66 - 72, The missing-metadata test is using a generic Exception, which
won’t match the real failure mode from importlib.metadata.version. Update
test_missing_metadata_is_skipped to patch importlib.metadata.version so it
raises importlib.metadata.PackageNotFoundError instead, and add the needed
importlib.metadata import at the top of the test module. This keeps
check_vllm_omni_compatibility exercised through the intended skip path and
aligns the test with version_check.py behavior.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@components/src/dynamo/vllm/omni/version_check.py`:
- Around line 33-41: Move the importlib.metadata dependency in version_check.py
to module scope and access it via importlib.metadata.version inside the version
check logic, rather than importing version inside the function. Narrow the
exception handling in the version check helper to only catch
importlib.metadata.PackageNotFoundError instead of a bare Exception, keeping the
existing debug log and early return for missing packages. Preserve test
patchability by continuing to resolve version through the module attribute
rather than binding a local imported function.

In `@components/src/dynamo/vllm/tests/omni/test_omni_version_check.py`:
- Around line 16-23: The spacing before the top-level helper `_fake_version` is
incorrect for `black`; add one more blank line after the `pytestmark` list so
there are two blank lines before the function definition, matching the
formatting expected by `black`.

---

Nitpick comments:
In `@components/src/dynamo/vllm/tests/omni/test_omni_version_check.py`:
- Around line 66-72: The missing-metadata test is using a generic Exception,
which won’t match the real failure mode from importlib.metadata.version. Update
test_missing_metadata_is_skipped to patch importlib.metadata.version so it
raises importlib.metadata.PackageNotFoundError instead, and add the needed
importlib.metadata import at the top of the test module. This keeps
check_vllm_omni_compatibility exercised through the intended skip path and
aligns the test with version_check.py behavior.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 12f873f1-125d-42b2-b89c-d3ccb0bdce07

📥 Commits

Reviewing files that changed from the base of the PR and between b650c53 and 501e23b.

📒 Files selected for processing (5)
  • components/src/dynamo/vllm/omni/__init__.py
  • components/src/dynamo/vllm/omni/version_check.py
  • components/src/dynamo/vllm/tests/omni/test_omni_version_check.py
  • container/context.yaml
  • container/deps/vllm/protected_packages.txt

Comment thread components/src/dynamo/vllm/omni/version_check.py Outdated
Comment thread components/src/dynamo/vllm/tests/omni/test_omni_version_check.py Outdated
tanmayv25 added 3 commits July 7, 2026 14:57
- Move importlib.metadata to module scope and access version via the
  module attribute (keeps test patchability of importlib.metadata.version).
- Narrow the caught exception to PackageNotFoundError instead of a bare
  Exception so unexpected errors propagate.
- Update the missing-metadata test to raise PackageNotFoundError.

Signed-off-by: tanmayv25 <tanmayv@nvidia.com>
Add the second blank line after the pytestmark list so there are two
blank lines before the top-level function, as black requires.

Signed-off-by: tanmayv25 <tanmayv@nvidia.com>
Signed-off-by: tanmayv25 <tanmayv@nvidia.com>
@alec-flowers

Copy link
Copy Markdown
Contributor

I wouldn't force bumping in cadence. vllm comes out ahead of vllm-omni so we can't gate on it.

tanmayv25 added 2 commits July 7, 2026 15:41
vLLM-Omni releases can lag vLLM, so the refs can't always be bumped in
lockstep; remove the comment implying they must match.

Signed-off-by: tanmayv25 <tanmayv@nvidia.com>
vLLM-Omni releases can lag vLLM, so a strict major/minor lockstep guard
is too restrictive. Remove version_check.py, its invocation in
omni/__init__.py, and the associated test.

Signed-off-by: tanmayv25 <tanmayv@nvidia.com>
@pull-request-size pull-request-size Bot added size/XS and removed size/L labels Jul 7, 2026
@tanmayv25

Copy link
Copy Markdown
Contributor Author

Duplicate: #11248

@tanmayv25 tanmayv25 changed the title fix(vllm): align vLLM-Omni pin with bundled vLLM and fail fast on mismatch fix(vllm): align vLLM-Omni pin with bundled vLLM 0.24.0 Jul 7, 2026
@tthakkal

tthakkal commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Duplicate: #11248

@tanmayv25 you can keep one and close other, your PR missing other required changes.
Removal of workaround logic in install_vllm_omni.sh and changes needed to fix failure tests.

@tanmayv25 tanmayv25 closed this Jul 7, 2026
@nv-rinig
nv-rinig deleted the tanmayv/fix-vllm-omni-version-mismatch branch July 8, 2026 19:52
@nv-rinig
nv-rinig restored the tanmayv/fix-vllm-omni-version-mismatch branch July 8, 2026 19:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants