[BugFix] add more is not None check in VllmConfig.__post_init__ (#12138)

Signed-off-by: Chen Zhang <zhangch99@outlook.com>
This commit is contained in:
Chen Zhang 2025-01-17 13:33:22 +08:00 committed by GitHub
parent b8bfa46a18
commit d1adb9b403
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -3174,7 +3174,8 @@ class VllmConfig:
if self.compilation_config is None:
self.compilation_config = CompilationConfig()
if envs.VLLM_USE_V1 and not self.model_config.enforce_eager:
if envs.VLLM_USE_V1 and self.model_config is not None and \
not self.model_config.enforce_eager:
# NOTE(woosuk): Currently, we use inductor because the piecewise
# CUDA graphs do not work properly with the custom CUDA kernels.
# FIXME(woosuk): Disable inductor to reduce the compilation time