From 2abbd351ef6436860cb3c64f66b1452c1d941fe4 Mon Sep 17 00:00:00 2001 From: 22quinn <33176974+22quinn@users.noreply.github.com> Date: Tue, 28 Oct 2025 06:52:47 -0700 Subject: [PATCH] [Core] Enable async scheduling for external_launcher mode (#27394) Signed-off-by: 22quinn <33176974+22quinn@users.noreply.github.com> Co-authored-by: Zhuohan Li --- vllm/engine/arg_utils.py | 7 ++++--- vllm/v1/engine/llm_engine.py | 4 +--- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/vllm/engine/arg_utils.py b/vllm/engine/arg_utils.py index ede470b08476a..e8f8e3f8c2b51 100644 --- a/vllm/engine/arg_utils.py +++ b/vllm/engine/arg_utils.py @@ -1553,11 +1553,12 @@ class EngineArgs: ) if self.async_scheduling and ( - parallel_config.distributed_executor_backend not in ("mp", "uni") + parallel_config.distributed_executor_backend + not in ("mp", "uni", "external_launcher") ): raise ValueError( - "Currently, async scheduling only supports `mp` or `uni` " - "distributed executor backend, but you choose " + "Currently, async scheduling only supports `mp`, `uni` or " + "`external_launcher` distributed executor backend, but you choose " f"`{parallel_config.distributed_executor_backend}`." ) diff --git a/vllm/v1/engine/llm_engine.py b/vllm/v1/engine/llm_engine.py index 0cd5e1ff3944e..486dacb2e5d9c 100644 --- a/vllm/v1/engine/llm_engine.py +++ b/vllm/v1/engine/llm_engine.py @@ -306,9 +306,7 @@ class LLMEngine: self.engine_core.abort_requests(processed_outputs.reqs_to_abort) # 4) Record stats - if self.logger_manager is not None: - assert outputs.scheduler_stats is not None - + if self.logger_manager is not None and outputs.scheduler_stats is not None: self.logger_manager.record( scheduler_stats=outputs.scheduler_stats, iteration_stats=iteration_stats,