【发布时间】:2021-04-16 19:21:40
【问题描述】:
正如标题所说,每当我尝试为 Visual Studio 2019 安装扩展时,VSIX 安装程序都会给出错误消息:Object reference not set to an instance of an object。我发现了一些类似的帖子,但没有什么与这里发生的事情完全一样。我尝试删除Appdata/Local 中的某些文件夹,尝试在控制台中运行devenv /resetuserdata。虽然似乎没有任何效果,所以我很好奇是否有其他人遇到过这个问题以及关于如何解决它的任何想法?
Picture of VSIX with Error Message
安装日志:
1/11/2021 12:59:18 PM - -------------------------------------------
1/11/2021 12:59:18 PM - vsixinstaller.exe version:
1/11/2021 12:59:18 PM - 16.8.3036
1/11/2021 12:59:18 PM - -------------------------------------------
1/11/2021 12:59:18 PM - Command line parameters:
1/11/2021 12:59:18 PM - C:\Program Files (x86)\Microsoft Visual Studio\Installer\resources\app\ServiceHub\Services\Microsoft.VisualStudio.Setup.Service\vsixinstaller.exe,/appidinstallpath:F:\VSCODEIDE\Common7\IDE\devenv.exe,/skuName:Community,/skuVersion:16.8.30804.86,/appidname:Microsoft Visual Studio Community 2019,/culture:en-US,/noep,C:\Users\xxxxxxx\AppData\Local\Temp\VSIXpg4jcyqq.vsix
1/11/2021 12:59:18 PM - -------------------------------------------
1/11/2021 12:59:18 PM - Microsoft VSIX Installer
1/11/2021 12:59:18 PM - -------------------------------------------
1/11/2021 12:59:18 PM - System.NullReferenceException: Object reference not set to an instance of an object.
at VSIXInstaller.SetupExtensions.GetLaunchableInstances(IQuery query)
at VSIXInstaller.SupportedSKUs.EnumerateIsolatedInstalls(Action`1 callback)
at VSIXInstaller.SupportedSKUs.AddInstalledLocationBasedSKUs(IntPtr userToken)
at VSIXInstaller.SupportedSKUs.InitializeSupportedSKUs(IntPtr userToken)
at VSIXInstaller.ExtensionService.InitializeSupportedSKUs(ICommandLineData cmdLineData, IntPtr duplicatedUserToken)
at VSIXInstaller.App.Initialize(Boolean isRepairSupported)
at VSIXInstaller.App.Initialize()
at System.Threading.Tasks.Task`1.InnerInvoke()
at System.Threading.Tasks.Task.Execute()
--- End of stack trace from previous location where exception was thrown ---
at Microsoft.VisualStudio.Telemetry.WindowsErrorReporting.WatsonReport.GetClrWatsonExceptionInfo(Exception exceptionObject)
【问题讨论】:
-
修复你的 VS 实例
标签: visual-studio visual-studio-2019 visual-studio-extensions vsix