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
Reduce log clutter by getting rid of duplicate Exception.ToString()
s
#1632
Comments
Does Serilog's default behavior maintain stack traces as well? If so, we'd better not to pass exceptions by hand. |
As far as I know, it does. In any case,
Automatically outputs the exception via the default setting of
where exception's What
does is that not only does it duplicate the printing of |
I haven't tested for unit tests since it might not be using the provided template, since |
Exception.Message
sException.ToString()
s
Update/Errata: It's actually |
This issue has been automatically marked as stale because it has not had recent activity. Thank you for your contributions. |
✋ |
This issue has been automatically marked as stale because it has not had recent activity. Thank you for your contributions. |
1 similar comment
This issue has been automatically marked as stale because it has not had recent activity. Thank you for your contributions. |
Default output format via
Serilog
is to have{exception}
at the end of log messages. This is to automatically output a message from a thrownExepction
when usingError()
. However, currently, many, if not most, ofSerilog
'sError()
in the code base explicitly includeException.Message
inmessage
parameter. The result is unnecessary cluttering of the log output with duplicatedException.Message
.The text was updated successfully, but these errors were encountered: