@tduncan / Nvidia-Optimization-Stack-VLLM Mirror · read-only / commits / c215f5c877
Fork 0

A high-throughput and memory-efficient inference and serving engine for LLMs

Mirrored from https://github.com/tduncan-lum/Nvidia-Optimization-Stack---VLLM.git

Synced Nov 14, 23:45 UTC

[Bug] Fix `has_flashinfer_moe` Import Error when it is not installed (#21634)

Signed-off-by: yewentao256 <zhyanwentao@126.com>

Wentao Ye committed Jul 26, 2025 at 10:06 UTC c215f5c877e0518f328613a98f31bb9cdb32a889
1 file changed +2 -1
vllm/utils/flashinfer.py
+2 -1
@@ -82,7 +82,8 @@ autotune = _lazy_import_wrapper(
82 @functools.cache
83 def has_flashinfer_moe() -> bool:
84 """Return ``True`` if FlashInfer MoE module is available."""
85 - return importlib.util.find_spec("flashinfer.fused_moe") is not None
85 + return has_flashinfer() and importlib.util.find_spec(
86 + "flashinfer.fused_moe") is not None
87
88
89 @functools.cache