刚刚打开VS 2015 Enterprise RTM,打开现有的工作项目,出现以下错误:
Microsoft Visual Studio
The 'NuGetPackage' package did not load correctly.
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
.Restarting Visual Studio could help resolve this issue.
Continue to show this error message?
[Yes] [No]
重新启动没有帮助。我检查了日志文件,发现以下与 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>
这会建议重复的扩展,但扩展管理器中似乎并非如此。
这是在一台也安装了 VS2013 的机器上。它从未安装过任何 VS2015 的预览/RC 版本。
最佳答案
通过扩展和更新完全删除 NuGet,重新启动 VS,然后通过扩展和更新重新安装 NuGet 解决了我的问题。无需重新安装完整的 VS。
关于nuget - VS2015 - 'NuGetPackage' 包未正确加载,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31521438/