Tuesday, November 1, 2016

Failed to initialize the PowerShell host

Got the following message after updating Visual Studio 2013 to Update 5.

Package Installation Error
Could not add all required packages to the project. The following packages failed to install from 'C:\Program Files (x86)\Microsoft ASP.NET\ASP.NET Web Stack 5\Packages':

jQuery.1.10.2 : Failed to initialize the PowerShell host. If your PowerShell execution policy setting is set to AllSigned, open the Package Manager Console to initialize the host first.
Modernizr.2.6.2 : Failed to initialize the PowerShell host. If your PowerShell execution policy setting is set to AllSigned, open the Package Manager Console to initialize the host first.

Fix was to install - following hotfix -

2.8.7 for VS 2013:
https://github.com/NuGet/Home/releases/download/2.8.7/NuGet.Tools.vsix

Or updating the NuGet library again after updating to Update 5. Logically it should be taken care by the update itself, but Microsoft Gods like one to spend some time on the internet.

No comments: