<#7504 fix(plugins/ray): disable ANSI color codes ...
# flyte-github
a
#7504 fix(plugins/ray): disable ANSI color codes and Ray Data progress bars in pod logs Pull request opened by 1fanwang Why are the changes needed? Ray decorates its output for an interactive terminal — ANSI-colored log prefixes and tqdm-style Ray Data progress bars. Flyte collects Ray pod stdout to a non-interactive log sink, where these turn into escape-sequence noise (
\x1b[2m\x1b[36m(pid=...)\x1b[0m
) and repeated progress-bar frames that hurt log readability and search. What changes were proposed in this pull request? Set two env vars on the Ray head and worker containers to turn the decorations off:
RAY_COLOR_PREFIX=0
(no ANSI in prefixes) and
RAY_DATA_DISABLE_PROGRESS_BARS=1
(no Ray Data progress bars). They sit alongside the existing
RAY_DISABLE_DOCKER_CPU_WARNING
and are no-ops on Ray builds that don't read them. How was this patch tested?
TestBuildResourceRay_DisablesLogNoiseEnv
asserts both land on the head and worker containers. Against a real Ray 2.55.1 runtime,
RAY_COLOR_PREFIX=0
strips the colored
(pid=…)
prefix that otherwise reaches the log sink; on a live KubeRay cluster the vars carry through to the running head pod's container. Labels fixed Check all the applicable boxes • I updated the documentation accordingly. • All new and existing tests passed. • All commits are signed-off. flyteorg/flyte