VSCode Powershell integrated terminal hangs when starting

Viewed 5842

I am using VSCode version 1.12.2 in Windows 10 x64 build 16193. I am trying to debug Powershell in VSCode, but I cannot get the PowerShell Integrated Terminal working. Every time I started the terminal, here's what I see:

VSCode Powershell terminal

And then it hangs in that stage. I can still debug, start, step in, step out..., but I cannot view my variable or run any expression.

My VSCode is using powershell x64 here:

"terminal.integrated.shell.windows": "C:\\WINDOWS\\Sysnative\\WindowsPowerShell\\v1.0\\powershell.exe"
3 Answers

I have had a similar problem, it seems. I cannot be sure it is the same, but when I would "load a file with VSCode" (user installer confirmed, system installer unconfirmed), it would hang. The following avenues tested:

  • Double-clicking on a PS1 file (the association to Code being made)
  • Starting VsCode empty and then loading the file
  • Starting VsCode from the command-line with a file-designation parameter

Using the --verbose switch, I got a listing which lead me to believe that VsCode seemed to be checking on updates using NPM (I could be wrong here). Whatever the underlying problem, I did a lot of prodding and probing, and the cure I found was this.

  • Delete the directory called C:\Users\YourUserId\.vscode.

This directory is rather large, is not wiped by software removal, and may be corrupted apparently. After deleting it, the problem disappeared.

Related