[CI] Support FORCE_COLOR env var; enable colors in CPU CI output (#56913)

Signed-off-by: Nick Hill <nickhill123@gmail.com>
This commit is contained in:
Nick Hill
2026-09-16 22:40:21 -04:00
committed by GitHub
parent fa3622a4a1
commit 5efbf0886a
5 changed files with 30 additions and 3 deletions
+1 -1
View File
@@ -29,7 +29,7 @@ _DATE_FORMAT = "%m-%d %H:%M:%S"
def _use_color() -> bool:
if envs.NO_COLOR or envs.VLLM_LOGGING_COLOR == "0":
return False
if envs.VLLM_LOGGING_COLOR == "1":
if envs.VLLM_LOGGING_COLOR == "1" or envs.FORCE_COLOR:
return True
if envs.VLLM_LOGGING_STREAM == "ext://sys.stdout": # stdout
return hasattr(sys.stdout, "isatty") and sys.stdout.isatty()