Open rainman110 opened 4 months ago
We could solve this using the logging system:
Most destinations have a dedicated formatter object that denotes how a message is logged. For us this is usually LEVEL [TIME] [ID] MESSAGE
(this behavior is implemented by gt::log::Formatter::Default
).
However, there is also a formatter, that only logs the message for gtInfo
(no time, no level etc.). Warnings, Errors etc are not affected and will be logged as usual. The formatter is called gt::log::Formatter::MessageOnly
.
We could use the MessageOnly
formatter for the console and switch to the Default
formatter once we execute the desired function (or we could not switch at all and only use the MessageOnly
formatter for the console)
Idea: establish a guildeline for console communication (@jensschmeink @rainman110 make a meeting to generate first version of guildeline)
Summary
We currently use gtError etc, when reporting any messages. This also applies to the console app.
IMHO, user argument errors of the console app should not be reported as a log message, but printed via cerr (as a matter of style). Or at least without the date and id (to be discussed)!
Impact on the codebase
Batch application
Current workarounds
No response