You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
tl;dr, if you have a licensed version, you should upgrade to at least 1.4.1.
choco upgrade chocolatey.extension - this package is only available for licensed versions of choco
After further review, we determined it is actually an issue with how the licensed version was taking a dependency on System.Management.Automation that was incorrect, causing it to attempt to load only v3 and above. This means that if you were running PowerShell v2, the licensed assembly would not load correctly, causing other issues when trying to install packages.
This is easily seen if you run into it attempting to load the same version of System.Management.Automation several times.
Could not load file or assembly 'System.Management.Automation, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.'Could not load file or assembly 'System.Management.Automation, Version=3.0.0.0,
Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.'
Could not load file or assembly 'System.Management.Automation, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.'
Original
An issue was uncovered that attempting to upgrade PowerShell with Chocolatey creates a lock on the binaries that PowerShell is attempting to upgrade.
When attempting to install/upgrade PowerShell, there could be an issue that occurs that sets the system into a state where Chocolatey is not able to be used:
Could not load file or assembly 'System.Management.Automation, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.'
It cycles through all of the possibilities and can not find a suitable PowerShell to install.
We can attempt to do one of the following:
create a copy of those binaries and use those for the dependencies and then delete them after the run.
automatically fall back to system PowerShell when we see a particular update that is for PowerShell libraries.
something else
Of course my vote is for option 1.
The text was updated successfully, but these errors were encountered:
So, I'm not sure what you mean by "attempting to upgrade PowerShell with Chocolatey". I'm not attempting to upgrade anything when this issue occurs. At most, I'm attempting to install a package, but not PowerShell. Do you mean a package that I am attempting to install is doing this (though, I'm pretty sure this last time, I was not actually installing anything)?
ferventcoder
changed the title
Upgrade of PowerShell with Chocolatey Host Causes Install Failure and Manual Remediation
Licensed version has an incorrect dependency on PowerShell assemblies and will only load v3 and above
Jun 14, 2016
Looks like I got a little ahead of myself. After further review, we determined it is actually an issue with how the licensed version was taking a dependency on System.Management.Automation that was incorrect, causing it to attempt to load only v3 and above. This means that if you were running PowerShell v2, the licensed assembly would not load correctly, causing other issues when trying to install packages.
tl;dr, if you have a licensed version, you should upgrade to at least 1.4.1.
choco upgrade chocolatey.extension
- this package is only available for licensed versions of chocoAfter further review, we determined it is actually an issue with how the licensed version was taking a dependency on System.Management.Automation that was incorrect, causing it to attempt to load only v3 and above. This means that if you were running PowerShell v2, the licensed assembly would not load correctly, causing other issues when trying to install packages.
This is easily seen if you run into it attempting to load the same version of System.Management.Automation several times.
Original
An issue was uncovered that attempting to upgrade PowerShell with Chocolatey creates a lock on the binaries that PowerShell is attempting to upgrade.When attempting to install/upgrade PowerShell, there could be an issue that occurs that sets the system into a state where Chocolatey is not able to be used:It cycles through all of the possibilities and can not find a suitable PowerShell to install.We can attempt to do one of the following:create a copy of those binaries and use those for the dependencies and then delete them after the run.automatically fall back to system PowerShell when we see a particular update that is for PowerShell libraries.something elseOf course my vote is for option 1.The text was updated successfully, but these errors were encountered: