The log carries terminal colour codes when nobody is at a terminal #88

Closed
opened 2026-09-29 06:28:35 -07:00 by rays · 1 comment
Owner

tracing-subscriber's fmt layer writes ANSI colour escapes by default, and ipx does not turn them off when stderr is not a terminal, so docker logs and Loki (via Alloy) get lines like '\x1b[2m2026-09-29T12:42:47Z\x1b[0m \x1b[32m INFO\x1b[0m ...'. Every grep and LogQL query has to strip them first. Found building a Grafana dashboard on iPX's Loki logs.

tracing-subscriber's fmt layer writes ANSI colour escapes by default, and ipx does not turn them off when stderr is not a terminal, so docker logs and Loki (via Alloy) get lines like '\x1b[2m2026-09-29T12:42:47Z\x1b[0m \x1b[32m INFO\x1b[0m ...'. Every grep and LogQL query has to strip them first. Found building a Grafana dashboard on iPX's Loki logs.
rays added the bug label 2026-09-29 06:28:35 -07:00
Author
Owner

Fixed in 9e7c93e: colour only when stderr is a terminal. Deployed.

Fixed in 9e7c93e: colour only when stderr is a terminal. Deployed.
rays closed this issue 2026-09-29 06:35:45 -07:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: rays/ipx#88