Skip to content

Commit 8d775dd

Browse files
authored
[Misc] Fix Unable to detect current VLLM config. Defaulting to NHD kv cache layout warning (#20400)
Signed-off-by: NickLucche <nlucches@redhat.com>
1 parent 78fe775 commit 8d775dd

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

vllm/distributed/kv_transfer/kv_connector/utils.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,10 +97,10 @@ def get_kv_connector_cache_layout():
9797
# used for faster transfer.
9898
vllm_config = get_current_vllm_config()
9999
kv_config = vllm_config.kv_transfer_config
100-
if vllm_config.model_config is None or kv_config is None:
100+
if kv_config is not None and vllm_config.model_config is None:
101101
logger.warning_once("Unable to detect current VLLM config. " \
102102
"Defaulting to NHD kv cache layout.")
103-
else:
103+
elif kv_config is not None:
104104
use_mla = vllm_config.model_config.use_mla
105105
if not use_mla and kv_config.kv_connector == "NixlConnector":
106106
logger.info_once("NixlConnector detected. Setting KV cache " \

vllm/v1/attention/backends/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ def get_kv_cache_layout():
138138
if cache_layout is None:
139139
cache_layout = get_kv_connector_cache_layout()
140140
else:
141-
logger.info_once("`FLASHINFER_KV_CACHE_LAYOUT` environment variable " \
141+
logger.info_once("`VLLM_KV_CACHE_LAYOUT` environment variable " \
142142
"detected. Setting KV cache layout to %s.", cache_layout)
143143

144144
return cache_layout

0 commit comments

Comments
 (0)