[Core] Model console logging as CLI configuration (#57205)

Add `--logging-config` CLI argument which can be supplied as
JSON or using dotted arguments. The `--log-level` argument
is provided for convenience, and `--log-config-file` is deprecated
in favor of `--logging-config.pylogging_config_file`.

Signed-off-by: Mark McLoughlin <markmc@redhat.com>
Co-authored-by: AI Assistant <noreply@openai.com>
This commit is contained in:
Mark McLoughlin
2026-09-25 11:36:59 +01:00
committed by GitHub
co-authored by AI Assistant
parent fa6c407d15
commit 45d56c0baf
36 changed files with 439 additions and 134 deletions
+3 -2
View File
@@ -4,6 +4,7 @@
from __future__ import annotations
import contextlib
import logging
import multiprocessing
import os
import signal
@@ -63,7 +64,7 @@ def suppress_stdout():
"""Suppress stdout from C libraries at the file descriptor level.
Only suppresses stdout, not stderr, to preserve error messages.
Suppression is disabled when VLLM_LOGGING_LEVEL is set to DEBUG.
Suppression is disabled when vLLM debug logging is enabled.
Example:
with suppress_stdout():
@@ -72,7 +73,7 @@ def suppress_stdout():
"""
# Don't suppress if logging level is DEBUG
if envs.VLLM_LOGGING_LEVEL == "DEBUG":
if logger.isEnabledFor(logging.DEBUG):
yield
return