Skip to content

Commit 5ce7cfc

Browse files
chenjiaoAngelweikaiwen
andcommitted
[rollout] fix: Add "non_block" argument compatibility to collective_rpc() (volcengine#3934)
### What does this PR do? This PR fixes a `TypeError` that occurs when newer versions of vLLM (v0.11+) attempt to call `ExternalZeroMQDistributedExecutor.collective_rpc`. The issue stems from a recent vLLM update (vllm-project/vllm#24219) that added the keyword argument `non_block` to the `Executor.collective_rpc` interface. Since the `verl` implementation of `collective_rpc` did not define this parameter, calling it with `non_block=True` resulted in the error: `TypeError: ExternalZeroMQDistributedExecutor.collective_rpc() got an unexpected keyword argument 'non_block'`. By using `**extra_kwargs` in the function signature, we ensure compatibility with both legacy and modern vLLM interfaces without affecting the existing ZeroMQ non-blocking logic. ### Checklist Before Submitting > [!IMPORTANT] > Please check all the following items before requesting a review, otherwise the reviewer might deprioritize this PR for review. - [x] Read the [Contribute Guide](https://github.com/volcengine/verl/blob/main/CONTRIBUTING.md). - [x] Apply [pre-commit checks](https://github.com/volcengine/verl/blob/main/CONTRIBUTING.md#code-linting-and-formatting): `pre-commit install && pre-commit run --all-files --show-diff-on-failure --color=always` - [ ] Add / Update [the documentation](https://github.com/volcengine/verl/tree/main/docs). - [ ] Add unit or end-to-end test(s) to [the CI workflow](https://github.com/volcengine/verl/tree/main/.github/workflows) to cover all the code. If not feasible, explain why: ... - [ ] Once your PR is ready for CI, send a message in [the `ci-request` channel](https://verl-project.slack.com/archives/C091TCESWB1) in [the `verl` Slack workspace](https://join.slack.com/t/verl-project/shared_invite/zt-3855yhg8g-CTkqXu~hKojPCmo7k_yXTQ). (If not accessible, please try [the Feishu group (飞书群)](https://applink.larkoffice.com/client/chat/chatter/add_by_link?link_token=772jd4f1-cd91-441e-a820-498c6614126a).) --------- Co-authored-by: weikaiwen <[email protected]>
1 parent 08ba3a9 commit 5ce7cfc

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

verl/workers/rollout/vllm_rollout/vllm_async_server.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,7 @@ def collective_rpc(
9595
timeout: Optional[float] = None,
9696
args: tuple = (),
9797
kwargs: Optional[dict[str, Any]] = None,
98+
**extra_kwargs,
9899
) -> list[Any]:
99100
if isinstance(method, str):
100101
sent_method = method

0 commit comments

Comments
 (0)