Prevent remote worker STDOUT log to add the name/pid decorator

How severe does this issue affect your experience of using Ray?

  • Low: It annoys or frustrates me for a moment.

My issue
My software uses logging.getLogger(__name__).warning to log information to stdout.

My output is in JSON, and I grab it from kubernetes logging ELK stack (filebeat->ES).

Log example
{ “error_type”: 1, “message”: “…” }

My issue is that if I try to log from a remote function, I get this decorator:
(remote_function_name pid=560) { “error_type”: 2, “message”: “…” }

And because of this, my ELK stack is not able to parse this JSON… Any way to disable the worker STDOUT decorator?

Hi @jaimehrubiks, thank you for posting!

@sangcho Do you know if it’s possible to remove the task function name and PID prefix from these logs?

No. There’s no way to remove this currently.

@jaimehrubiks can you create an issue to our Github to support this?