Closed jcollie closed 2 years ago
I think this makes sense and should be a relatively small change to https://github.com/openfaas/of-watchdog/blob/a0289419078824f0a070860f84a6b383eb4f2169/executor/logging.go
@jcollie would you be willing to open a Pull Request?
Thanks for the issue and PR. Does this also affect the classic watchdog?
Does this also affect the classic watchdog?
Not from what I saw, but I've never personally used the classic watchdog and I only spent a few minutes looking at the code.
If you set the environment variable prefix_logs to false, % signs are interpreted by of-watchdog as fmt.Printf verbs.
Expected Behaviour
% signs should not be interpreted
Current Behaviour
If your function logs "%s", of-watchdog substitutes "%!s(MISSING)"
Possible Solution
Don't use fmt.Printf() to log data from the function.
Steps to Reproduce (for bugs)
Context
Your Environment
Docker version
docker version
(e.g. Docker 17.0.05 ): 20.10.13Are you using Docker Swarm or Kubernetes (FaaS-netes)? Kubernetes 1.23.5
Operating System and version (e.g. Linux, Windows, MacOS): CentOS 7
Link to your project or a code example to reproduce issue: