Closed dbuenzli closed 8 years ago
Also possibly the src
.
(Currently in logs/src/logs_stdo.ml
the parameter src
is unused.)
(Currently in logs/src/logs_stdo.ml the parameter src is unused.)
Yes. I think it's good to have a simple base logger that is not too precise about these things.
I was a bit surprise when the default logger printed a prefix (Sys.argv.(0)
) but not the src
.
If you don't print the src
in the default logger, why print the tags
? What makes tags more deserving of printing-by-default? (Genuine question.)
I was a bit surprise when the default logger printed a prefix (Sys.argv.(0)) but not the src.
The reason is that I don't want every tool out there that uses the default logger to log on stderr without prefixing the tool name: if you don't do so it makes it impossible to determine which tool is reporting messages e.g. in scripts. So the default tries to enforce the good behaviour.
If you don't print the src in the default logger, why print the tags? What makes tags more deserving of printing-by-default? (Genuine question.)
I don't think I'll print the tags either, but I was unsure about that at some point so I'm going to close this. In a6270300aa3 I added a note that Logs_stdo
doesn't include information about sources or tags in its report.
Currently default loggers do not print message tags. Maybe they should.