-
-
Notifications
You must be signed in to change notification settings - Fork 103
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
internal/logger: send any logging message to stderr
Our internal logger was sending Error messages to stderr and all the other levels (Info, Warn and Debug) to stdout. However, both POSIX stds and part of the utility development community that "diagnostic" messages should go only to stderr, leaving stdout for the actual results of the program. Even though the logger messages are quite differet (prefixed by date, file and line) from lab's actual results, it forces a program receiving the stdout though a, eg., pipe to filter logger messages if only the actual results are required. One example of this issue was presented in lab's issue 789 [1], which was solved in a different way, but failed because a "diagnostic" message was feed into the `source` utility. This patch redirects all logging messages (not actual lab results) to stderr. [1] #789 Signed-off-by: Bruno Meneguele <bmeneg@redhat.com>
- Loading branch information
Showing
2 changed files
with
19 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters