Skip to content

Conversation

@njhill
Copy link
Member

@njhill njhill commented Sep 19, 2025

Generalization of #21845, support arbitrarily nested combinations of dicts and lists in returned types.

This is needed for #18465.

Signed-off-by: Nick Hill <nhill@redhat.com>
Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request generalizes the serialization of collective_rpc return types to support arbitrarily nested lists and dictionaries, which is a valuable enhancement. The core logic is implemented through new recursive encoding and decoding functions in vllm/v1/serial_utils.py, and the changes are well-covered by new tests. My review includes suggestions to improve the robustness of the deserialization logic by adding assertions to guard against potential data mismatches, which could lead to silent errors.

Signed-off-by: Nick Hill <nhill@redhat.com>
Copy link
Member

@DarkLight1337 DarkLight1337 left a comment

Choose a reason for hiding this comment

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

Thanks for taking the time to implement this!

@DarkLight1337 DarkLight1337 enabled auto-merge (squash) September 20, 2025 00:35
@github-actions github-actions bot added the ready ONLY add when PR is ready to merge/full CI is needed label Sep 20, 2025
@DarkLight1337 DarkLight1337 merged commit 535d800 into vllm-project:main Sep 20, 2025
51 checks passed
@njhill njhill deleted the util_return_dict branch September 21, 2025 15:15
FeiDaLI pushed a commit to FeiDaLI/vllm that referenced this pull request Sep 25, 2025
charlifu pushed a commit to ROCm/vllm that referenced this pull request Sep 25, 2025
Signed-off-by: Nick Hill <nhill@redhat.com>
Signed-off-by: charlifu <charlifu@amd.com>
yewentao256 pushed a commit that referenced this pull request Oct 3, 2025
Signed-off-by: Nick Hill <nhill@redhat.com>
Signed-off-by: yewentao256 <zhyanwentao@126.com>
xuebwang-amd pushed a commit to xuebwang-amd/vllm that referenced this pull request Oct 10, 2025
Signed-off-by: Nick Hill <nhill@redhat.com>
Signed-off-by: xuebwang-amd <xuebwang@amd.com>
choprahetarth pushed a commit to Tandemn-Labs/vllm that referenced this pull request Oct 11, 2025
lywa1998 pushed a commit to lywa1998/vllm that referenced this pull request Oct 20, 2025
xuebwang-amd pushed a commit to xuebwang-amd/vllm that referenced this pull request Oct 24, 2025
Signed-off-by: Nick Hill <nhill@redhat.com>
Signed-off-by: xuebwang-amd <xuebwang@amd.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready ONLY add when PR is ready to merge/full CI is needed v1

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants