VS2015 - 'NuGetPackage' 包未正确加载 [英] VS2015 - The 'NuGetPackage' package did not load correctly
问题描述
刚刚打开VS 2015 Enterprise RTM,打开一个现有的工作项目,得到如下错误:
Just opened up VS 2015 Enterprise RTM, opened up an existing working project, getting the following error:
微软 Visual Studio
Microsoft Visual Studio
NuGetPackage"包未正确加载.
The 'NuGetPackage' package did not load correctly.
问题可能是由配置更改或安装其他扩展引起的.您可以通过检查文件 C:\Users\REDACTED\AppData\Roaming\Microsoft\VisualStudio\14.0\ActivityLog.xml
来获取更多信息.
The problem may have been caused by a configuration change or by the installation of another extension. You can get more information by examining the file C:\Users\REDACTED\AppData\Roaming\Microsoft\VisualStudio\14.0\ActivityLog.xml
.
重新启动 Visual Studio 可以帮助解决此问题.
Restarting Visual Studio could help resolve this issue.
继续显示此错误消息?
[是] [否]
重新启动没有帮助.我检查了日志文件,发现以下与 nuget 相关的部分:
Restarting didn't help. I've examined the log file, and found the following sections relevant to nuget:
<entry>
<record>555</record>
<time>2015/07/20 16:06:34.364</time>
<type>Error</type>
<source>Extension Manager</source>
<description>Extension will not be loaded because an extension with the same ID
'Microsoft.Dev14.VsixTemplatesPackage.443cca91-ec20-41e5-a165-f28e56b89650'
is already loaded at C:\PROGRAM FILES (X86)\MICROSOFT VISUAL STUDIO 14.0\COMMON7\IDE\
EXTENSIONS\G2URSPAC.VAZ\...</description>
<path>C:\PROGRAM FILES (X86)\MICROSOFT VISUAL STUDIO 14.0\COMMON7\IDE\EXTENSIONS\
NUGETIFIEDEXTENSIBILITYTEMPLATES\</path>
</entry>
<entry>
<record>556</record>
<time>2015/07/20 16:06:34.364</time>
<type>Error</type>
<source>Extension Manager</source>
<description>Extension will not be loaded because an extension with the same ID
'Microsoft.VisualStudio.TeamFoundation.TeamExplorer.Extensions' is already
loaded at C:\PROGRAM FILES (X86)\MICROSOFT VISUAL STUDIO 14.0\COMMON7\IDE\EXTENSIONS\
B1NUOYPH.H2N\...</description>
<path>C:\PROGRAM FILES (X86)\MICROSOFT VISUAL STUDIO 14.0\COMMON7\IDE\COMMONEXTENSIONS\
MICROSOFT\TEAMFOUNDATION\TEAM EXPLORER\</path>
</entry>
这会建议重复扩展,但扩展管理器中似乎并非如此.
Which would suggest a duplicate extension, but this doesn't seem to be the case in the extensions manager.
这是在一台也安装了 VS2013 的机器上.它从未安装过任何 VS2015 的预览版/RC 版本.
This is on a machine that also has VS2013 installed. It has not had any of the preview/RC builds of VS2015 installed ever.
推荐答案
通过扩展和更新完全删除 NuGet,重新启动 VS,然后通过扩展和更新重新安装 NuGet 为我解决了这个问题.不需要完整的 VS 重新安装.
Completely removing NuGet via Extensions and Updates, restarting VS then re-installing NuGet via Extensions and Updates solved the issue for me. A full VS reinstall was not necessary.
这篇关于VS2015 - 'NuGetPackage' 包未正确加载的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!