Skip to content

Commit 0c84ba2

Browse files
committed
fix missing vllm.envs.env_var
Signed-off-by: Linkun Chen <[email protected]>
1 parent d70dfd7 commit 0c84ba2

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

python/ray/llm/_internal/serve/deployments/llm/vllm/vllm_engine.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,11 @@ def __init__(
200200
connector_type = getattr(kv_transfer_config, "kv_connector", "")
201201
if connector_type != "NixlConnector":
202202
raise ValueError("Only NixlConnector is supported for kv transfer.")
203-
if not vllm.envs.is_set("VLLM_NIXL_SIDE_CHANNEL_PORT"):
203+
if "VLLM_NIXL_SIDE_CHANNEL_PORT" not in vllm.envs.environment_variables:
204+
logger.warning(
205+
"This vLLM version does not support VLLM_NIXL_SIDE_CHANNEL_PORT environment variable. It's likely that you are using an older version of vLLM."
206+
)
207+
elif not vllm.envs.is_set("VLLM_NIXL_SIDE_CHANNEL_PORT"):
204208
port: int = vllm.utils.get_open_port()
205209
os.environ["VLLM_NIXL_SIDE_CHANNEL_PORT"] = str(port)
206210

0 commit comments

Comments
 (0)