我试图调试此消息:当添加nuget包时,有时候在别的时候使用的参考信息不是...如何阻止它?
The type 'Logging.LoggingProvider' is defined in an assembly that is not referenced. You must add a reference to assembly 'Logging.LoggingProvider, Version=1.0.0.0, Culture=neutral, PublicKeyToken=71561dfc7a07d5da'.
我有一个链中彼此依赖几个的NuGet包。在挖掘构建这些包的项目文件时,我发现组件被引用的方式稍有不同。有些人拥有钥匙,有些则不具备钥匙。这使我相信,如果我找到一种方法使nuget创建的参考文献保持一致,我的问题就会消失。
组件一次签署。我认为引用行为改变了,如果我从项目中删除签署的程序集= false,但似乎并非如此。
例如以1种溶液我已经使用相同的NuGet包和版本在2个不同项目中的参考文献中是不同的
不正确的一个(或至少不期望的)
<Reference Include="Logging.LoggingProvider, Version=1.0.0.0, Culture=neutral, PublicKeyToken=71561dfc7a07d5da, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\packages\Logging.LoggingProvider.1.0.24\lib\Logging.LoggingProvider.dll</HintPath>
</Reference>
并且在另一项目中的正确的是
<Reference Include="Logging.LoggingProvider, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\packages\Logging.LoggingProvider.1.0.24\lib\Logging.LoggingProvider.dll</HintPath>
</Reference>
什么可能导致这种情况?我真的把nuget包添加到1个项目然后下一个..一个作品,另一个不 - 我不能看到解释为什么项目文件中的任何东西。
其他人注意到棘手的问题不会得到答案吗? –