使用PackageReference通配符时依赖项出现黄色三角但无报错
Yellow Warning Triangle for NuGet Package with Wildcard Version (6.*) in .NET Core Class Library
I’ve been diving into NuGet versioning lately, specifically experimenting with wildcard versions after learning about version ranges and wildcards. I set up a PackageReference in my .NET Core class library like this:
<PackageReference Include="AutoMapper" Version="6.*" />
The problem is, after saving this change, the AutoMapper dependency shows a yellow warning triangle in Visual Studio—but there’s no accompanying error or warning message to explain what’s wrong. I’ve already tried standard troubleshooting steps: running NuGet restore, cleaning the entire project, and even restarting Visual Studio, but the triangle won’t go away.
How to Reproduce the Issue:
- Create a new .NET Core class library project
- Install the AutoMapper NuGet package, specifically version 6.2.2
- Open the project file, modify the Version attribute from
6.2.2to6.*, then save the file
I’m at a loss here—any insights or fixes would be really appreciated!
内容的提问来源于stack exchange,提问作者David.L
相关产品推荐
相关产品推荐

