When I run my application, this exception is thrown even before the start of debugging. enter image description here
System.IO.FileNotFoundException: 'Could not load file or assembly 'Serilog.Extensions.Hosting, Version=7.0.0.0, Culture=neutral, PublicKeyToken=24c2f752a8e58a10'. Le fichier spécifié est introuvable.'
This is my .csproj references :
<PackageReference Include="Serilog" Version="3.0.1" />
<PackageReference Include="Serilog.AspNetCore" Version="7.0.0.0" />
<PackageReference Include="StackExchange.Redis" Version="2.6.122" />
<PackageReference Include="Swashbuckle.AspNetCore" Version="6.5.0" />
I tried to clean and build the entire solution and projects so many times also dotnet restore.
Try
Otherwise it may be that you need to install another netcore runtime.