[Log] Update to log once (#46511)

Signed-off-by: yewentao256 <zhyanwentao@126.com>
Co-authored-by: TJian <tunjian.tan@embeddedllm.com>
This commit is contained in:
Wentao Ye
2026-06-24 14:45:16 +00:00
committed by GitHub
co-authored by TJian
parent 24d5186138
commit 007b5a52ed
4 changed files with 23 additions and 21 deletions
+8 -6
View File
@@ -220,15 +220,17 @@ class CudaPlatformBase(Platform):
try:
import vllm._C_stable_libtorch # noqa: F401
except ImportError as e:
logger.warning("Failed to import from vllm._C_stable_libtorch: %r", e)
logger.warning_once("Failed to import from vllm._C_stable_libtorch: %r", e)
try:
import vllm._moe_C_stable_libtorch # noqa: F401
except ImportError as e:
logger.warning("Failed to import from vllm._moe_C_stable_libtorch: %r", e)
logger.warning_once(
"Failed to import from vllm._moe_C_stable_libtorch: %r", e
)
try:
import vllm._qutlass_C # noqa: F401
except ImportError as e:
logger.warning("Failed to import from vllm._qutlass_C: %r", e)
logger.warning_once("Failed to import from vllm._qutlass_C: %r", e)
@property
def supported_dtypes(self) -> list[torch.dtype]:
@@ -291,7 +293,7 @@ class CudaPlatformBase(Platform):
# kernel with limited pinned memory support for CUDA.
version = _get_wsl_kernel_version()
if version is None or version < (4, 19, 121):
logger.warning(
logger.warning_once(
"Using 'pin_memory=False' as WSL is detected and the "
"WSL2 kernel version is below 4.19.121. This may slow "
"down performance. Please run `wsl --update`."
@@ -320,7 +322,7 @@ class CudaPlatformBase(Platform):
and scheduler_config.is_multimodal_model
and not scheduler_config.disable_chunked_mm_input
):
logger.warning(
logger.warning_once(
"Forcing --disable_chunked_mm_input for models "
"with multimodal-bidirectional attention."
)
@@ -331,7 +333,7 @@ class CudaPlatformBase(Platform):
and vllm_config.offload_config.uva.cpu_offload_gb > 0
and bool(vllm_config.compilation_config.cudagraph_mode)
):
logger.warning(
logger.warning_once(
"--cpu-offload-gb is enabled with CUDA graphs on WSL2. "
"This combination requires pinned (page-locked) memory "
"allocations. WARNING: Windows (WDDM) enforces a hard "