-
Notifications
You must be signed in to change notification settings - Fork 70
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
request: add 'success' log level #88
Comments
I would like this too! |
I have just discovered the glorious charm universe and the logging aspect has drawn my attension as I'm looking to integrate charm's log into some of my own projects. I noticed this issue, which initially seemed like a good idea, but after I did a little research, I came to conclusion that it is not and the reason is standards. Logging has a long history and has evolved from standards, in particluar, the syslog standard and also see RFC-5424. Actually I found a very good blog post: logging levels explained that may interest you. If you need a custom new non standard log level (even if its just a synonym for INFO), then it would be unadvisbable to implement in charm, it would be better for you to do this in a fork and doing so in charm would encourage third parties to become dependent on non standard functionality. If any change is made, then the TRACE level could be added as that is in the standard, but I get it, this won't help your use case. |
Hello, I have a similar usecase, but I think a workaround maybe to allow the kv pairs to overwrite the level maybe? it could be opt in with a new option from the config, I will work it out some other way but just wanted to let this idea. |
Log v0.4.0 is out now! closing... |
I just wanted to add a note here that for full functionality, you can also override Here's how that is in my wrapper that adds a trace level:
|
Example
Where the output in this case would be green and have a prefix similar to
SUCC
.This would be at the same level as "Info" but offer an alternative style
The text was updated successfully, but these errors were encountered: