You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed that LMMS does not have a convenient mechanism for debug messages, printfs are used instead.
My proposal is to create a flexible, yet easy to use mechanism:
The developer would use dedicated macros named, let's say, Log_Fatal, Log_Error, Log_Warn, Log_Info, Log_Dbg, Log_Dbg_Super - listed here in ascending level of verbosity
The functions above would accept the same syntax as printf function, since they would actually encapsulate (sn|f)printfs.
The tracing mechanism would forward appropriate mechanism to a few sinks. Two kinds of those come to my mind right now: console output and log file output.
Each sink would be assigned a level of verbosity. Let's say, by default the console would be filled up with fatal errors, errors and warnings, while the logfile would include info and normal debug messages as well. This way the console will not be spammed with uninteresting messages, still preserving more detailed information in the log file.
The default tracing levels would be modifiable via command line arguments, as such:
$ ./lmms --log-console=info, --log-file=dbg-super
They also could be configured in the main configuration window.
Each log line, besides the log message, would include the information about its severity, the timestamp, name of the source file and number of the line, like this:
I-190901-12:34:56.789012-vestige.cpp:123: Program change to 42
Use of log severity indicator {F, E, W, I, D, S} would allow a quick look-up for the messages in the log using vim, for example "G, ?^E" would jump to the last error message.
The console output would use the ANSI escape sequences to color the messages
The text was updated successfully, but these errors were encountered:
I noticed that LMMS does not have a convenient mechanism for debug messages, printfs are used instead.
My proposal is to create a flexible, yet easy to use mechanism:
Use of log severity indicator {F, E, W, I, D, S} would allow a quick look-up for the messages in the log using vim, for example "G, ?^E" would jump to the last error message.
The text was updated successfully, but these errors were encountered: