-
Notifications
You must be signed in to change notification settings - Fork 986
Logging: Add log stream that only get sent warning+ logs. #5311
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Hey @widlarizer, please take a look when you get a chance, thank you! |
Seems like |
Renamed, thanks :) |
I'm in favor of the LogSeverity struct and an overloaded log function seems like a decent way to safely retrofit it. Is there an intended followup that exposes |
I've rewritten this PR in light of the log changes by @rocallahan. One notable consequence of this PR is that Regarding the last comment (@widlarizer): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is no code in this PR appending to log_warning_streams
Also, this breaks |
Sorry -- I misunderstood. We'll be appending to |
We'd like to subscribe to only the most critical logs. Currently, there is no way to specify a log level threshold. This PR provides a stopgap solution.
In addition to the log_streams vector that new log sinks can push to, this PR adds a log_warning_streams vector that behaves similarly, but ostreams in this new vector only receive warning and error logs.