Skip to content

Commit ea3372f

Browse files
authored
[Bugfix][KV Pool]fix get_ip import in mooncake_store (#4355)
### What this PR does / why we need it? fix import error for get_ip() in vllm main branch ### Does this PR introduce _any_ user-facing change? N ### How was this patch tested? - vLLM version: v0.11.0 - vLLM main: vllm-project/vllm@2918c1b --------- Signed-off-by: pz1116 <[email protected]>
1 parent 9b3a484 commit ea3372f

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

vllm_ascend/distributed/mooncake/mooncake_store.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,19 @@
55
from mooncake.store import ReplicateConfig # type: ignore
66
from vllm.config import ParallelConfig
77
from vllm.distributed.parallel_state import get_tensor_model_parallel_rank
8-
from vllm.utils import get_ip, logger
8+
from vllm.utils import logger
99

1010
from vllm_ascend.distributed.mooncake.config_data import MooncakeEngineKey
1111
from vllm_ascend.distributed.mooncake.transfer_engine import get_global_te
12+
from vllm_ascend.utils import vllm_version_is
1213

1314
from .config_data import MooncakeStoreConfig
1415

16+
if vllm_version_is("0.11.0"):
17+
from vllm.utils import get_ip
18+
else:
19+
from vllm.utils.network_utils import get_ip
20+
1521
METADATA_BYTES_LEN = 24
1622
BASE_PORT = int(os.getenv("VLLM_BASE_PORT", "8790"))
1723

0 commit comments

Comments
 (0)