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
When I added a PSR-3 logger to Robo, the existing code was printing most progress text via a 'printTaskInfo()' function. I decided to map that to LogLevel::NOTICE, and adjusted things so that notices were printed by Robo. Seems to work out to me; WARNING is a different level entirely (more severe), and, while the kinds of things Robo was printing via printTaskInfo was interesting to the commandline user, it seemed that a non-verbose log (e.g. on a server) might just omit these.
Drush sort of had this problem too; we solved the problem of log messages that were not WARNING level, but should be printed all the time by introducing OK and SUCCESS log levels. The difference between these were always somewhat ambiguous, and the problem remains that there are still some messages we might want to print that are not necessarily "OK" or "SUCCESS". Also, NOTICE is a standard PSR-3 / rfc5424 log level, whereas OK and SUCCESS are not.
When I implemented the core-init command as an annotation command with Robo tasks, I bumped NOTICE up so that it would print all the time; however, this introduced a lot of extra noise that we normally did not see, as Drush currently expects that NOTICE logs are only displayed in verbose mode. My plan is to change all of the existing NOTICE logs to INFO. Currently, Drush core has 13 logs that are emitted at NOTICE, and 4 that are emitted at INFO.
The technical difference between NOTICE and INFO are minimal; the RFC is not really clear about what log levels should be displayed or filtered under what conditions; I think the assumption is that this is decided by the application, and it seems to be further assumed that the application selects the minimum log level to show by selecting one of the defined log levels -- there is no standard mapping from verbose to NOTICE or greater, etc. -- although most implementations seem to omit NOTICE unless verbose.
I'd like to continue to display NOTICE at normal (non-verbose) output, and demote existing NOTICE logs to INFO (which is only displayed with VERBOSE output).
The text was updated successfully, but these errors were encountered:
When I added a PSR-3 logger to Robo, the existing code was printing most progress text via a 'printTaskInfo()' function. I decided to map that to LogLevel::NOTICE, and adjusted things so that notices were printed by Robo. Seems to work out to me; WARNING is a different level entirely (more severe), and, while the kinds of things Robo was printing via printTaskInfo was interesting to the commandline user, it seemed that a non-verbose log (e.g. on a server) might just omit these.
Drush sort of had this problem too; we solved the problem of log messages that were not WARNING level, but should be printed all the time by introducing OK and SUCCESS log levels. The difference between these were always somewhat ambiguous, and the problem remains that there are still some messages we might want to print that are not necessarily "OK" or "SUCCESS". Also, NOTICE is a standard PSR-3 / rfc5424 log level, whereas OK and SUCCESS are not.
When I implemented the core-init command as an annotation command with Robo tasks, I bumped NOTICE up so that it would print all the time; however, this introduced a lot of extra noise that we normally did not see, as Drush currently expects that NOTICE logs are only displayed in verbose mode. My plan is to change all of the existing NOTICE logs to INFO. Currently, Drush core has 13 logs that are emitted at NOTICE, and 4 that are emitted at INFO.
The technical difference between NOTICE and INFO are minimal; the RFC is not really clear about what log levels should be displayed or filtered under what conditions; I think the assumption is that this is decided by the application, and it seems to be further assumed that the application selects the minimum log level to show by selecting one of the defined log levels -- there is no standard mapping from verbose to NOTICE or greater, etc. -- although most implementations seem to omit NOTICE unless verbose.
I'd like to continue to display NOTICE at normal (non-verbose) output, and demote existing NOTICE logs to INFO (which is only displayed with VERBOSE output).
The text was updated successfully, but these errors were encountered: