Skip to content

Latest commit

 

History

History
26 lines (18 loc) · 914 Bytes

File metadata and controls

26 lines (18 loc) · 914 Bytes
title description author ms.author ms.date ms.topic f1_keywords
NuGet Warning NU1508
NU1508 warning code
zivkan
zivkan
08/10/2024
reference
NU1508

NuGet Warning NU1508

Scenario 1

Duplicate 'NuGetAuditSuppress' items found. Remove the duplicate items or use the Update functionality to ensure a consistent restore behavior. The duplicate 'NuGetAuditSuppress' items are: https://contoso.test/cve/1 , https://contoso.test/cve/1 .

Issue

Sometimes when adding NuGetAuditSuppress items, you may end up adding an item for a particular package multiple times.

MSBuild projects commonly import multiple .props and .targets files, so the duplicates might not be in the same file, but may be in included files, such as Directory.Build.props, Directory.Packages.props, or Directory.Build.targets.

Solution

Remove the duplicate item, so that it's included exactly once.