Skip to content

Commit d73f260

Browse files
authored
[FIX_FOR_VLLM_LATEST] fix issue brought by upstream PR #25893 (#310)
vllm-project/vllm#25893 Signed-off-by: Chendi Xue <Chendi.Xue@intel.com>
1 parent 13c0d71 commit d73f260

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

vllm_gaudi/platform.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,11 @@
88

99
from vllm import envs
1010

11-
from vllm.platforms import Platform, PlatformEnum, _Backend
11+
from vllm.platforms import Platform, PlatformEnum
1212
from vllm_gaudi.extension.runtime import get_config
1313

1414
if TYPE_CHECKING:
15+
from vllm.attention.backends.registry import _Backend
1516
from vllm.config import ModelConfig, VllmConfig
1617
else:
1718
ModelConfig = None
@@ -39,7 +40,7 @@ class HpuPlatform(Platform):
3940
additional_env_vars = [k for k, v in os.environ.items() if retain_envs(k)]
4041

4142
@classmethod
42-
def get_attn_backend_cls(cls, selected_backend: _Backend, head_size: int, dtype: torch.dtype,
43+
def get_attn_backend_cls(cls, selected_backend: "_Backend", head_size: int, dtype: torch.dtype,
4344
kv_cache_dtype: Optional[str], block_size: int, use_v1: bool, use_mla: bool,
4445
has_sink: bool, use_sparse: bool) -> str:
4546
assert use_v1, 'Only V1 is supported!'

0 commit comments

Comments
 (0)