Skip to content
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

Serilog dont logging #31

Closed
NurdaKz opened this issue Feb 10, 2021 · 2 comments
Closed

Serilog dont logging #31

NurdaKz opened this issue Feb 10, 2021 · 2 comments

Comments

@NurdaKz
Copy link

NurdaKz commented Feb 10, 2021

After this line in Program.cs, nothing is logged

Log.CloseAndFlush();

@alydemah
Copy link

alydemah commented Jul 5, 2021

Had the same issue, you need to move this line inside try catch block in Program.cs

  try
   {

 ///..... Other code
await host.RunAsync();


}


@virux99
Copy link

virux99 commented Aug 27, 2021

Had the same issue, you need to move this line inside try catch block in Program.cs

  try
   {

 ///..... Other code
await host.RunAsync();


}

thanks @alydemah this solved the issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants