Skip to content

1.101.0 breaks with powershell 7.5 installed on computer #251446

Open
@chrisduda

Description

@chrisduda

I'm having an issue with a system after the 1.101.0 update. I use VSC for powershell with one terminal session and powershell extension in another. Both are running Windows PS 5.1 and I have Powershell 7.5 installed also. After the upgrade, none of my modules will load in VSC. When I run get-module I only see powershell 7 compatible modules. $env:psmodulepath shows all of the correct paths but if I run a get-module -listavailable, I only see the powershell 7 and windows system paths. If I drill down to where I have my other modules and try to load them, I get the error that there's no maifest file. This is happening on the windows powershell terminal session while on my powershell extension session never finishes loading. On that session, it's asking me in the lower right corner to pick a language which powershell is the default. If I downgrade to 1.100.3, the system is fine. If I leave 1.101.0 installed and remove powershel 7.5, the system runs normal. Reinstalling 7.5 breaks VSC again.

With VSC 1.101.0 after update:
Sessions come up with PS 5.1 showing manifest 7.0.0.0 Microsoft.Powershell.management and no modules will load.
With 1.100.3 or 1.101.0 with powershell 7.5 later removed:
Sessions come up with PS 5.1 showing manifest 3.1.0.0 Microsoft.Powershell.management everything runs fine.

It leads me to believe that VSC is attempting to load powershell 7.5 and the system can't process it. However I've been able to use PS 7.5 sessions in VSC 1.100.3 and older and it's always run fine. I also did try using information from #251311 to use code to remove the powershell 7 paths from starting up and loading and it did show the manifest ver 3 on my powershell session however none of the modules would load. Same error that it can't find the manifest files.

I also have another system that took the upgrade fine and everything is working the way it always has. I have setting sync enabled and have the workspace set up the same on both system. I downgraded the one system to 1.100.3 and kept powershell 7.5 installed as I have jobs that run that require 7. The system that is working is a windows 11 laptop and the one having issues after the update is server 2022, 21h2. I did also try disabling extensions and it was to no avail as well as removing my powershell startup profiles.

Metadata

Metadata

Labels

bugIssue identified by VS Code Team member as probable bugimportantIssue identified as high-priorityregressionSomething that used to work is now brokenwindowsVS Code on Windows issues

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions