I have the following warning
Severity Code Description Project File Line Suppression State
Warning NETSDK1071 A PackageReference to \'Microsoft.Asp
There's a few ways around this.
If you include the PackageReference
but remove the Version
attribute, it should make the warning go away. This is because it is a metapackage, which (simply put) is a type of package that gets the version based on your framework version, more here: https://docs.microsoft.com/en-us/dotnet/core/packages#metapackages
To disable the warnings, add AllowExplicitVersion
:
<PackageReference Include="Microsoft.AspNetCore.App" Version="2.1.11" >
<AllowExplicitVersion>true</AllowExplicitVersion>
</PackageReference>
More here: https://github.com/dotnet/sdk/issues/2602