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
After call AddNLog
header is written twice
#708
Comments
@snakefoot can you check it please? |
Could you include a minimal reproducable example in source-code? (Or even better an unit-test). Maybe also the output from NLog InternalLogger. |
Tried to reproduce based on you initial details. And failed to reproduce. Succes with both |
Could you send me the project with reproduction please? I will try to correct it completely with my logic |
Just adapt one of the example projects for this git-repo. Maybe using a pull request
|
@snakefoot PR with reproduce: #709 |
When calling Try using |
I can't find a description of this anywhere. + It is not clear what other methods can lead to this. I think it's worth updating the documentation |
I'm guessing that the behavior was seen as implicit, when calling /// <summary>
/// Enable NLog as logging provider for Microsoft Extension Logging
/// </summary>
/// <param name="builder"></param>
/// <param name="configuration">New NLog config.</param>
/// <returns>ILoggingBuilder for chaining</returns>
public static ILoggingBuilder AddNLog(this ILoggingBuilder builder, LoggingConfiguration configuration) But all improvements to documentation are always wellcome. Like the goal of preventing users from faling into traps. |
@RomanSoloweow Created #710 that tries to improve the XML docs for |
Closing issue, as the reason has been found. And #710 has been committed, which tries to improve XML-docs. |
After call
AddNLog
header is written twiceSteps to reproduce
AddNLog
After call
AddNLog
header is written twice. If you don't call AddNLog, everything works as expectedI don’t know what the reason could be, but it looks like AddNlog causes FileTarget to be reinitialized or creates its own using the same layout
The text was updated successfully, but these errors were encountered: