[misc] improve error message for "Failed to infer device type" (#15994)

Signed-off-by: youkaichao <youkaichao@gmail.com>
This commit is contained in:
youkaichao 2025-04-03 14:45:03 +08:00 committed by GitHub
parent 06f21ce7a5
commit 5e125e74d1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1875,7 +1875,10 @@ class DeviceConfig:
from vllm.platforms import current_platform
self.device_type = current_platform.device_type
if not self.device_type:
raise RuntimeError("Failed to infer device type")
raise RuntimeError(
"Failed to infer device type, please set "
"the environment variable `VLLM_LOGGING_LEVEL=DEBUG` "
"to turn on verbose logging to help debug the issue.")
else:
# Device type is assigned explicitly
self.device_type = device