NuGet Errors and Warnings Reference (original) (raw)
In this article
In NuGet 4.3.0+, errors and warnings are numbered as described in this topic and provide detailed information to help you address the issues involved.
The errors and warnings listed here are available only with PackageReference-based projects and NuGet 4.3.0+. NuGet also honors MSBuild properties to suppress warnings or elevate them to errors. For more information, see How to: Suppress Compiler Warnings in the Visual Studio documentation.
NuGet supports the following configuration properties.
Property
Scope
Description
TreatWarningsAsErrors
Project
Treats all NuGet warnings as errors
NoWarn
Project, PackageReference, ProjectReference
Suppress the warning for the current project, package or project reference
WarningsAsErrors
Project
Treat certain warnings as errors
WarningsNotAsErrors
Project
Treat certain warnings not as errors. Used in combination with TreatWarningsAsErrors set to true.