Vscode: Terminal on Windows 7 does not show any text

Created on 8 Feb 2018  ·  138Comments  ·  Source: microsoft/vscode

  • VSCode Version: 1.20.0
  • OS Version: win7 SP1 X64

Steps to Reproduce:

1.When I use ctrl+~ open the terminal, can't input anything in the terminal
2.And I also find when I right-click a folder, the option [open in the terminal ] is instead of [open in the cmd], but my "terminal.integrated.shell.window has been config to powershell.exe
3.It happened after I updated to the latest version.
4.It cannot be solved after restarting the system or vscode.
5.The powershell outside is working normally.


Does this issue occur when all extensions are disabled?: Yes
01

*out-of-scope bug integrated-terminal windows

Most helpful comment

i also have this problem

All 138 comments

i also have this problem

Does it show when you toggle the terminal (ctrl+`, ctrl+`) or zoom in and out (ctrl++, ctrl+-)?

Also are there any errors in the devtools console (Help > Toggler Developer Tools)

@Tyriar I can use these shortcuts to toggle the terminal or zoom in and out. Devtools have no error, there are a warning:

Ctrl+Alt+ keybindings should not be used by default under Windows.

image

I tried to specify powershell and git-bash, reinstall vscode, restart computer, ban all extensions. terminal still no response.

mark!

mark

revert to last version,reinstall 1.19.2
the terminal will show again

版本 1.19.2
提交 490ef761b76b3f3b3832eff7a588aac891e5fe80
日期 2018-01-10T15:55:03.538Z
Shell 1.7.9
渲染器 58.0.3029.110
Node 7.9.0
架构 x64

@Tyriar

  1. 'Does it show when you toggle the terminal (ctrl+, ctrl+) or zoom in and out (ctrl++, ctrl+-)?'
    A: It shows with a block where I can input nothing.
  2. 'Also are there any errors in the devtools console (Help > Toggler Developer Tools)'
    A: Yes,but i seems has no relation with terminal.
    a1

After disabling these extensions.
02

3.The problem disapperred for one day(I did nothing) . But it(the problem) appear again today(I did nothing),
and I have no idea about that.

版本 1.20.0
提交 c63189deaa8e620f650cc28792b8f5f3363f2c5b
日期 2018-02-07T17:09:39.780Z
Shell 1.7.9
渲染器 58.0.3029.110
Node 7.9.0
架构 x64

Seems like a System Permissions issue.
Find Code.exe in the installation path, check run as administrator and back to normal.

@woshiguabi not the case for me. Even running as admin still doesn't fix it. (On insiders anyway)

Okay so, disabling compatibility mode seems to fix it, regardless of if run is administrator is enabled or not.

Okay so, disabling compatibility mode seems to fix it, regardless of if run is administrator is enabled or not.

@bitcrazed FYI, this might be another Windows regression

@woshiguabi good, thank you

Been noticing this as well. It's weird though because the terminal will work fine for a bit and I can run node commands, ionic commands, etc. I'll minimize code or drag to a new window and terminal disappears. I can get it back by clicking the garbage can and re-opening the terminal with Ctrl+J

This is really difficult to track down without a repro. If anyone has specific repro steps, please share.

Thanks.

same problem

For me this happens in the following case reproducably (on Windows):

  • Open new VSCode which starts out maximized
  • Open console (I'm using WSL bash as shell, in case that matters)
  • Restore window (everything still fine at that point)
  • Maximize window again (Shell vanished and no amount of scrolling or pressing keys will make it come back)

@davec21 @CherryDT the dragging/maximizing part makes me think you're seeing https://github.com/Microsoft/vscode/issues/42999 which is fixed in Insiders and can be worked around in the meantime by hiding and showing the terminal.

@Tyriar Hm you are right. I wrote this before I updated my insider VSCode to the latest version. It's fixed in 1.21

I can provide more informations about the terminal problem , recently.

1.It often occurs when I close the vscode rough,like shutdowning my system without closing the vscode.exe or close the vscode while the terminal is working.
2.And I also found a solution: File =>Create a new window. In this case,even the old window‘s terminal still can't work normally, but new window's terminal is nomal!

@Tyriar @bitcrazed Maybe it can help you to find the reason.

old
new

Can people who are having this issue test whether it repros within insiders? There is an issue which looks very similar to this which is fixed already https://code.visualstudio.com/insiders/

Yes, my original issue was with insiders and testing now again it's still an issue with insiders. If I enable Windows 8 compatibility mode, the terminal fails to load and just appears blank, if I disable it again, it works as intended.

@Technoblazed oh I missed the part about compatibility mode, are you running VS Code in compatibility mode 😕

I was running it in compatibility mode so it could be detected by display capture on my OBS, but obviously I'd rather have the terminal working than my display capture ;)

I can reproduce the terminal not working in Windows 8 compatibility mode, but that also happens in v1.19 and it was mentioned that it works there https://github.com/Microsoft/vscode/issues/43169#issuecomment-364663482, I even checked 1.17 and it's the same. I wonder if it only worked when downgrading because it's a new executable that's not running in compatibility mode anymore?

If this is all related to compatibility mode and the terminal I don't really understand why there was a huge influx of reports for this issue recently, unless many people were upgrading from Windows 8 to 10 recently for some reason (compat mode is set automatically when upgrading AFAIK)? Or maybe that's just the confusion over https://github.com/Microsoft/vscode/issues/42999 which is hard for people to tell apart from this.

It looks like the reason the terminal doesn't die is because the backing shell process is actually still running:

image

Also the OP reported using Windows 7. For people who can reproduce on Insiders can you check whether you're running under compatibility mode and let me know what your OS is and what compatibility mode is on? To check this you can right click on the executable then go to properties -> compatibility.

Windows 10, compatibility set to 8

@Technoblazed did you upgrade recently?

There's actually a section in the FAQ I added a long time ago I just remembered 😄 https://code.visualstudio.com/docs/editor/integrated-terminal#_common-questions

Actually, I noticed that this started becoming an issue after the latest Windows creators update a month or two ago, and as for insiders I updated yesterday I believe. As I said earlier, the only reason for me using compatibility mode was so that I could capture the content.

@Technoblazed interesting, but the terminal worked fine before then? The old behavior which triggered me to update the docs was that the terminal would exit and show a notification. Did you upgrade from Windows 8 at some point or was this a fresh Windows 10 install or upgrade from Windows 7?

Oh you mentioned you had compat mode for some display capture thing, did you set this manually?

Yeah I manually enabled it months ago and it was fine, just until the recent creators update that it broke. And this was a fresh install of Win 10 Pro

@Technoblazed thanks for all the info 😃

@bitcrazed TLDR: This is probably not the OP's issue, but it looks like the terminal no longer runs when Windows 10 is running under Windows 8 compat mode. It worked fine before FCU though. We don't explicitly support this but could have contributed to the influx of reports here.

@Tyriar
I have the same issue. Insider version is the latest.

image

And the following is the logs when I add a new terminal:
image

System: Windows 7
Compability Mode: off

I've had a very similar issue, but it was totally my mistake. I forgot to add bash.exe or powershell.exe in the end of the path

I have the same problem in win7:
image
but it is work fine in win10

@lizhihua0925 @daix6 Choose New Window from the File menu, it works for me,you can make a try.

@Bendjen Sadly not work for me

Ok I think the OP's issue is about the terminal just not working on Windows 7 https://github.com/Microsoft/vscode/issues/43169, I think the other reports are separate issues (Windows 8 compat mode not supported, maximize can hide text).

But it worked in Windows 7 before actually, and suddenly broke one day...

@Bendjen Oh, it's not work for me ( win 7, vscode 1.20.1)

I suppose Automatic Updates made this situation now,because today I clicked 'confirm' to autoupdate vsCode to 1.21.0 during the terminal was working, and when it finished and reopened , my terminal disappearred again. The first time of the situation appearring is the time when I updated vsCode to 1.20.0, so I realize maybe it's not the version problem,it‘s’ caused by the update operation probably. @Tyriar

The terminal surprisingly works today. And I've done nothing. No updating, no configuration...

@daix6 are you on Windows 7? 😕What version of VS Code are you on (including commit/date if you're on Insiders)?

@Tyriar I'm on windows 7 and am seeing the issue while running the following version of VSCode:

Version 1.21.1
Commit 79b44aa704ce542d8ca4a3cc44cfca566e7720f1
Date 2018-03-14T14:46:47.128Z
Shell 1.7.9
Renderer 58.0.3029.110
Node 7.9.0
Architecture x64

I am not running in compatibility mode, and the 'New Window' workaround doesn't work for me. Also if i 'Run as Administrator', the integrated terminal loads fine, but running as a normal user, it doesn't.

Been having the same issue for 3 months on Windows 10 #40175

@mtpultz do you have compatibility mode on?

I'm experiencing this on Win 10 with compatibility mode off for Code.

@Tyriar yes, i'm on windows 7. I updated the vs code to 1.21.1 after my terminal works.

@WackyWesley you should create a new issue to discuss there

So to try to summarize...
Issue: Blank integrated terminal

Issue Details

  • Issue is seen across Windows versions (7,8,10).
  • Issue is seen across code versions (1.21.0, 1.21.1).
  • Issue is seen even when all extensions are disabled.
  • Issue does not seem to provide helpful console logs (#40175)

Some Workarounds that have been reported with mixed success rates:

  • Issue can _sometimes_ be sidestepped by turning off compatibility mode. (@Technoblazed)
  • Issue can _sometimes_ be sidestepped by upgrading to v1.21.1 (@daix6)
  • Issue can _sometimes_ be sidestepped by opening a new code window via File menu (@Bendjen)
  • Issue can _sometimes_ be sidestepped by running code as administrator (@woshiguabi)

@meichthys I think we've narrowed the OP's issue here to Windows 7 (https://github.com/Microsoft/vscode/issues/43169#issuecomment-370925501), so let's track that specifically here. Anything on Windows 8 or 10 should be in a different issue.

@Tyriar Installing an older version has fixed the issue for me.
I installed: https://code.visualstudio.com/updates/v1_20
I'll plan on running this version until the issue is resolved.

I just got a Windows 7 VM up and running and both cmd and powershell work fine in 1.20.1, 1.21.1 and 1.22.0-insiders.

I wonder if it's related to Windows Defender somehow? We've run into issues in the past with Windows Defender slowing things down but perhaps it's quarantining critical files? I'll update my VM and defender and do a scan and see if that finds anything. If anyone who is seeing the issue could check Defender that would be helpful.

@Tyriar Hmm. interesting. I have windows defender disabled. When i get a chance, I'll try re-updating to 1.21.1 to see if i still have the issue.

@meichthys do you have any other anti-virus or similar software that could be doing something similar?

I do. I've tried disabling the antivirus while updating/installing/running with no luck.
I also just tried using the built-in updater to update to the latest version, and I'm seeing the same issue again (Running as admin works though).

@meichthys could you check the user permissions of this file?

C:\Program Files\Microsoft VS Code\resources\app\node_modules\node-pty\build\Release\winpty-agent.exe

This is what mine looks like:

screen shot 2018-03-27 at 11 24 35 am

@Tyriar my permissions look identical to yours, but my path to that file is slightly different:
C:\Program Files\Microsoft VS Code\resources\app\ node_modules.asar.unpacked \node-pty\build\Release

@meichthys ah that's because I had v1.20.1 installed at the time, mine has that path if I move to 1.21.1

@meichthys something else you can try:

  1. Install VS Code Insiders (if not already)
  2. Close all Insiders windows
  3. Open cmd.exe
  4. Run code-insiders --log trace
  5. Open the terminal
  6. Open the command palette (F1) and run the "Developer: Open Log File..." command
  7. Paste in what you see

Here's mine:

[2018-03-27 11:45:14.190] [renderer1] [trace] openWorkbench configuration {"_":[],"help":false,"h":false,"version":false,"v":false,"wait":false,"w":false,"diff":false,"d":false,"add":false,"a":false,"goto":false,"g":false,"new-window":false,"n":false,"unity-launch":false,"reuse-window":false,"r":false,"open-url":false,"performance":false,"p":false,"prof-startup":false,"verbose":false,"logExtensionHostCommunication":false,"disable-extensions":false,"disableExtensions":false,"list-extensions":false,"show-versions":false,"nolazy":false,"issue":false,"skip-getting-started":false,"skip-release-notes":false,"sticky-quickopen":false,"disable-restore-windows":false,"disable-telemetry":false,"disable-updates":false,"disable-crash-reporter":false,"skip-add-to-recently-opened":false,"status":false,"s":false,"file-write":false,"file-chmod":false,"log":"trace","appRoot":"c:\\Program Files\\Microsoft VS Code Insiders\\resources\\app","machineId":"9aec06d7ba7c54a98ecbfa544862e4058bea4c014088f181619dcb42349a904c","execPath":"C:\\Program Files\\Microsoft VS Code Insiders\\Code - Insiders.exe","userEnv":{"VSCODE_IPC_HOOK":"\\\\.\\pipe\\491ddf78bc8e277b81b63c379151c48e-1.22.0-insider-main-sock","VSCODE_NLS_CONFIG":"{\"locale\":\"en-us\",\"availableLanguages\":{}}","VSCODE_LOGS":"C:\\Users\\daimms\\AppData\\Roaming\\Code - Insiders\\logs\\20180327T114513"},"isInitialStartup":true,"filesToOpen":[],"filesToCreate":[],"filesToDiff":[],"nodeCachedDataDir":"C:\\Users\\daimms\\AppData\\Roaming\\Code - Insiders\\CachedData\\d656cdac7d61c16330520420e57a103697dde16d","backupPath":"C:\\Users\\daimms\\AppData\\Roaming\\Code - Insiders\\Backups\\1522176226069","windowId":1,"logLevel":0,"fullscreen":false,"highContrast":false,"accessibilitySupport":false,"baseTheme":"vs-dark","backgroundColor":"#1e1e1e","perfEntries":["mark","main:started",1522176313090,0,"mark","main:appReady",1522176313122,0,"mark","main:loadWindow",1522176313324,0],"perfStartTime":1522176313090,"perfWindowLoadTime":1522176313324}
[2018-03-27 11:45:14.206] [renderer1] [trace] lifecycle: starting up (startup kind: 1)
[2018-03-27 11:45:14.226] [renderer1] [trace] lifecycle: phase changed (value: 2)
[2018-03-27 11:45:14.424] [renderer1] [trace] lifecycle: phase changed (value: 3)
[2018-03-27 11:45:17.435] [renderer1] [trace] lifecycle: phase changed (value: 4)
[2018-03-27 11:45:17.953] [renderer1] [trace] terminalInstance#ctor (id: 1) {}
[2018-03-27 11:45:18.362] [renderer1] [debug] Terminal process ready (id: 1, processId: 3124)
[2018-03-27 11:45:20.814] [renderer1] [trace] CommandService#executeCommand workbench.action.showCommands
[2018-03-27 11:45:21.644] [renderer1] [trace] CommandService#executeCommand workbench.action.openLogFile

@sbatten managed to repro the mysterious lone cursor terminal on Windows 10 but it was flaky. One thing to note is that terminal process ready event never happened for him:

[2018-03-27 11:45:18.362] [renderer1] [debug] Terminal process ready (id: 1, processId: 3124)

Also switching to powershell seemed to fix the issue and then back to cmd it was fixed.

The original repro happened after enabling narrator.

@Tyriar here's my log trace while running as admin (no issue). It looks very similar to yours...


[2018-03-27 15:20:46.530] [renderer1] [trace] openWorkbench configuration {"_":[],"help":false,"h":false,"version":false,"v":false,"wait":false,"w":false,"diff":false,"d":false,"add":false,"a":false,"goto":false,"g":false,"new-window":false,"n":false,"unity-launch":false,"reuse-window":false,"r":false,"open-url":false,"performance":false,"p":false,"prof-startup":false,"verbose":false,"logExtensionHostCommunication":false,"disable-extensions":false,"disableExtensions":false,"list-extensions":false,"show-versions":false,"nolazy":false,"issue":false,"skip-getting-started":false,"skip-release-notes":false,"sticky-quickopen":false,"disable-restore-windows":false,"disable-telemetry":false,"disable-updates":false,"disable-crash-reporter":false,"skip-add-to-recently-opened":false,"status":false,"s":false,"file-write":false,"file-chmod":false,"log":"trace","appRoot":"c:\\Program Files\\Microsoft VS Code Insiders\\resources\\app","machineId":"a0565eec5b67a97b961964ecf9bfbd91fe2662ed245ce10ed56b250a48bad3df","execPath":"C:\\Program Files\\Microsoft VS Code Insiders\\Code - Insiders.exe","userEnv":{"VSCODE_IPC_HOOK":"\\\\.\\pipe\\2f533cd3561e694c39f3bd3ae67904d8-1.22.0-insider-main-sock","VSCODE_NLS_CONFIG":"{\"locale\":\"en-us\",\"availableLanguages\":{}}","VSCODE_LOGS":"C:\\Users\\restore\\AppData\\Roaming\\Code - Insiders\\logs\\20180327T152045"},"isInitialStartup":true,"filesToOpen":[],"filesToCreate":[],"filesToDiff":[],"nodeCachedDataDir":"C:\\Users\\restore\\AppData\\Roaming\\Code - Insiders\\CachedData\\d656cdac7d61c16330520420e57a103697dde16d","backupPath":"C:\\Users\\restore\\AppData\\Roaming\\Code - Insiders\\Backups\\1522177986943","windowId":1,"logLevel":0,"fullscreen":false,"highContrast":false,"accessibilitySupport":false,"baseTheme":"vs-dark","backgroundColor":"#1e1e1e","perfEntries":["mark","main:started",1522178445038,0,"mark","main:appReady",1522178445059,0,"mark","main:loadWindow",1522178445235,0],"perfStartTime":1522178445038,"perfWindowLoadTime":1522178445236}
[2018-03-27 15:20:46.539] [renderer1] [trace] lifecycle: starting up (startup kind: 1)
[2018-03-27 15:20:46.555] [renderer1] [trace] lifecycle: phase changed (value: 2)
[2018-03-27 15:20:46.691] [renderer1] [trace] lifecycle: phase changed (value: 3)
[2018-03-27 15:20:48.020] [renderer1] [trace] CommandService#executeCommand setContext
[2018-03-27 15:20:49.702] [renderer1] [trace] lifecycle: phase changed (value: 4)
[2018-03-27 15:20:52.301] [renderer1] [trace] CommandService#executeCommand workbench.action.terminal.toggleTerminal
[2018-03-27 15:20:52.303] [renderer1] [trace] terminalInstance#ctor (id: 1) {}
[2018-03-27 15:20:52.671] [renderer1] [debug] Terminal process ready (id: 1, processId: 2544)
[2018-03-27 15:21:02.134] [renderer1] [trace] CommandService#executeCommand workbench.action.showCommands
[2018-03-27 15:21:09.985] [renderer1] [trace] CommandService#executeCommand workbench.action.openLogFile

... and here it is while running as user (issue persistent):

[2018-03-27 15:27:15.015] [renderer1] [trace] openWorkbench configuration {"_":[],"help":false,"h":false,"version":false,"v":false,"wait":false,"w":false,"diff":false,"d":false,"add":false,"a":false,"goto":false,"g":false,"new-window":false,"n":false,"unity-launch":false,"reuse-window":false,"r":false,"open-url":false,"performance":false,"p":false,"prof-startup":false,"verbose":false,"logExtensionHostCommunication":false,"disable-extensions":false,"disableExtensions":false,"list-extensions":false,"show-versions":false,"nolazy":false,"issue":false,"skip-getting-started":false,"skip-release-notes":false,"sticky-quickopen":false,"disable-restore-windows":false,"disable-telemetry":false,"disable-updates":false,"disable-crash-reporter":false,"skip-add-to-recently-opened":false,"status":false,"s":false,"file-write":false,"file-chmod":false,"log":"trace","appRoot":"c:\\Program Files\\Microsoft VS Code Insiders\\resources\\app","machineId":"a0565eec5b67a97b961964ecf9bfbd91fe2662ed245ce10ed56b250a48bad3df","execPath":"C:\\Program Files\\Microsoft VS Code Insiders\\Code - Insiders.exe","userEnv":{"VSCODE_IPC_HOOK":"\\\\.\\pipe\\9e6e98061bb7eefb77a4c8ef5424b2a1-1.22.0-insider-main-sock","VSCODE_NLS_CONFIG":"{\"locale\":\"en-us\",\"availableLanguages\":{}}","VSCODE_LOGS":"C:\\Users\\mgieger\\AppData\\Roaming\\Code - Insiders\\logs\\20180327T152714"},"isInitialStartup":true,"filesToOpen":[],"filesToCreate":[],"filesToDiff":[],"nodeCachedDataDir":"C:\\Users\\mgieger\\AppData\\Roaming\\Code - Insiders\\CachedData\\d656cdac7d61c16330520420e57a103697dde16d","backupPath":"C:\\Users\\mgieger\\AppData\\Roaming\\Code - Insiders\\Backups\\1522177998428","windowId":1,"logLevel":0,"fullscreen":false,"highContrast":false,"accessibilitySupport":false,"baseTheme":"vs-dark","backgroundColor":"#1e1e1e","perfEntries":["mark","main:started",1522178834245,0,"mark","main:appReady",1522178834268,0,"mark","main:loadWindow",1522178834427,0],"perfStartTime":1522178834245,"perfWindowLoadTime":1522178834427}
[2018-03-27 15:27:15.025] [renderer1] [trace] lifecycle: starting up (startup kind: 1)
[2018-03-27 15:27:15.044] [renderer1] [trace] lifecycle: phase changed (value: 2)
[2018-03-27 15:27:15.088] [renderer1] [trace] lifecycle: phase changed (value: 3)
[2018-03-27 15:27:15.238] [renderer1] [trace] terminalInstance#ctor (id: 1) {}
[2018-03-27 15:27:16.643] [renderer1] [trace] CommandService#executeCommand setContext
[2018-03-27 15:27:18.102] [renderer1] [trace] lifecycle: phase changed (value: 4)
[2018-03-27 15:27:24.254] [renderer1] [trace] CommandService#executeCommand workbench.action.showCommands
[2018-03-27 15:27:25.711] [renderer1] [trace] CommandService#executeCommand workbench.action.openLogFile
[2018-03-27 15:27:27.125] [renderer1] [trace] CommandService#executeCommand workbench.action.openLogViewer

@meichthys great, I see terminal process ready didn't happen. I might try to squeeze in some additional logging in this upcoming version to help diagnose.

Sounds good. Let me know if you’d like me to run any other tests/logs.

@meichthys I just added a few more logs, if you could do the same log test in the new build tomorrow that would be great 😃

@Tyriar Thanks. Will do.

@meichthys the latest build should have the additional logging in place

@Tyriar The issue persists, and the log is mostly identical with the exception of a [debug] record which contains my path environment variable which i would rather not post publicly. Is there something you're looking for in the path?

@meichthys you can completely clear the env object part if you want, not interested in that

I don't think there was much else of interest, but here it is anyway:


[2018-03-29 15:13:43.255] [renderer1] [trace] openWorkbench configuration {"_":[],"help":false,"h":false,"version":false,"v":false,"wait":false,"w":false,"diff":false,"d":false,"add":false,"a":false,"goto":false,"g":false,"new-window":false,"n":false,"unity-launch":false,"reuse-window":false,"r":false,"open-url":false,"performance":false,"p":false,"prof-startup":false,"verbose":false,"logExtensionHostCommunication":false,"disable-extensions":false,"disableExtensions":false,"list-extensions":false,"show-versions":false,"nolazy":false,"issue":false,"skip-getting-started":false,"skip-release-notes":false,"sticky-quickopen":false,"disable-restore-windows":false,"disable-telemetry":false,"disable-updates":false,"disable-crash-reporter":false,"skip-add-to-recently-opened":false,"status":false,"s":false,"file-write":false,"file-chmod":false,"log":"trace","appRoot":"c:\\Program Files\\Microsoft VS Code Insiders\\resources\\app","machineId":"a0565eec5b67a97b961964ecf9bfbd91fe2662ed245ce10ed56b250a48bad3df","execPath":"C:\\Program Files\\Microsoft VS Code Insiders\\Code - Insiders.exe","userEnv":{"VSCODE_IPC_HOOK":"\\\\.\\pipe\\9e6e98061bb7eefb77a4c8ef5424b2a1-1.22.0-insider-main-sock","VSCODE_NLS_CONFIG":"{\"locale\":\"en-us\",\"availableLanguages\":{}}","VSCODE_LOGS":"C:\\Users\\mgieger\\AppData\\Roaming\\Code - Insiders\\logs\\20180329T151341"},"isInitialStartup":true,"filesToOpen":[],"filesToCreate":[],"filesToDiff":[],"nodeCachedDataDir":"C:\\Users\\mgieger\\AppData\\Roaming\\Code - Insiders\\CachedData\\952b2a641da89a6c7bc28387474bc8afd47f0d2f","backupPath":"C:\\Users\\mgieger\\AppData\\Roaming\\Code - Insiders\\Backups\\1522177998428","windowId":1,"logLevel":0,"fullscreen":false,"highContrast":false,"accessibilitySupport":false,"baseTheme":"vs-dark","backgroundColor":"#1e1e1e","perfEntries":["mark","main:started",1522350821667,0,"mark","main:appReady",1522350821698,0,"mark","main:loadWindow",1522350821932,0],"perfStartTime":1522350821667,"perfWindowLoadTime":1522350821932}
[2018-03-29 15:13:43.276] [renderer1] [trace] lifecycle: starting up (startup kind: 1)
[2018-03-29 15:13:43.293] [renderer1] [trace] lifecycle: phase changed (value: 2)
[2018-03-29 15:13:43.434] [renderer1] [trace] lifecycle: phase changed (value: 3)
[2018-03-29 15:13:43.517] [renderer1] [trace] terminalInstance#ctor (id: 1) {}
---env oject omitted---
[2018-03-29 15:13:45.068] [renderer1] [trace] CommandService#executeCommand setContext
[2018-03-29 15:13:46.476] [renderer1] [trace] lifecycle: phase changed (value: 4)
[2018-03-29 15:13:53.609] [renderer1] [trace] CommandService#executeCommand workbench.action.showCommands

here's the debug line:

[2018-03-29 15:13:43.517] [renderer1] [debug] Terminal process launching (id: 1) {"env": **left out**,"cwd":"c:\\Program Files\\Microsoft VS Code Insiders\\resources\\app\\out\\vs\\workbench\\parts\\terminal\\node"}

@meichthys interesting, this is telling me that the process starts but doesn't send any messages or exit, it's just sitting there. Could you try look at the process tree by running code-insiders --status and paste that in? The table with this header is what I'm after:

CPU %   Mem MB     PID  Process

Also can you get the table when you open multiple terminals as well?

here's what i get when running the status command:

Collecting CPU and memory information. This might take a couple of seconds.
[main 3:39:47 PM] Error: Get-WmiObject : Invalid class "Win32_Process"
At C:\Program Files\Microsoft VS Code Insiders\resources\app\out\vs\base\node\ps-win.ps1:114 char:19
+ foreach ($item in Get-WmiObject Win32_Process -Filter "name = '$ProcessName'") {
+                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidType: (:) [Get-WmiObject], ManagementException
    + FullyQualifiedErrorId : GetWMIManagementException,Microsoft.PowerShell.Commands.GetWmiObjectCom
   mand

Get-WmiObject : Invalid class "Win32_Process"
At C:\Program Files\Microsoft VS Code Insiders\resources\app\out\vs\base\node\ps-win.ps1:117 char:19
+ foreach ($item in Get-WmiObject Win32_Process -Filter "name = 'codeHelper.exe'") ...
+                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidType: (:) [Get-WmiObject], ManagementException
    + FullyQualifiedErrorId : GetWMIManagementException,Microsoft.PowerShell.Commands.GetWmiObjectCom
   mand

Get-WmiObject : Invalid class "Win32_Process"
At C:\Program Files\Microsoft VS Code Insiders\resources\app\out\vs\base\node\ps-win.ps1:121 char:19
+ foreach ($item in Get-WmiObject Win32_Process -Filter "name Like '%'") {
+                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidType: (:) [Get-WmiObject], ManagementException
    + FullyQualifiedErrorId : GetWMIManagementException,Microsoft.PowerShell.Commands.GetWmiObjectCom
   mand


    at ChildProcess.<anonymous> (C:\Program Files\Microsoft VS Code Insiders\resources\app\out\vs\code\electron-main
\main.js:157:375)
    at emitTwo (events.js:106:13)
    at ChildProcess.emit (events.js:194:7)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:215:12)

@meichthys 😕 that looks like a bug, created https://github.com/Microsoft/vscode/issues/46963 to follow that up. Instead of --status then, could you try getting and pasting in the process tree under VS Code using ProcessExplorer?

image

As you expected, each terminal that i open in code adds another process which doesn't close even when i click the delete terminal icon (trash can) in vs code.

@meichthys hmm, that's not exactly what I was expecting, could you add the "command line" (or "arguments"?) column so we can make sure we know which is which?

'''
image
'''
sorry the image is so small.. This shows three terminal processes (i started three terminals and then closed 2, but three processes are still showing)

@meichthys perfect! Thanks for sticking with me 😄

The --type=terminal process is meant to always have children (conhost.exe, winpty-agent.exe and cmd.exe/powershell.exe/etc). My current theory is something is failing when launching the winpty agent process such that it never fires its exit event. And then the reason that the --type=terminal process never shuts down is because we set up intervals which keep the node process alive.

Looking into it more now.

I can't see anything in recent versions of node-pty that would impact terminal init on Windows https://github.com/Tyriar/node-pty/compare/0.7.1...0.7.4

I'm not sure if this helps:
image

Seems to be that I fixed terminal for myself. I had user settings file with redefinition of terminal type (cmd to bash):
"terminal.integrated.shell.windows": "C:\\Program Files\\Git\\bin\\bash.exe",

But I found that after update this settings key have different name in default settings:
"terminal.external.windowsExec": "C:\\windows\\System32\\cmd.exe",

So I changed user settings accordingly and problem has gone:
"terminal.external.windowsExec": "C:\\Program Files\\Git\\bin\\bash.exe"

@Riconec Thanks for the suggestion, but both the terminal.integrated.shell.windows and the terminal.external.windowsExec settings exist in v1.21.1. Maybe @Tyriar could help clarify the difference between the two settings. For me, both of those settings have the same path: "C:\\Windows\\System32\\cmd.exe"

@Riconec @meichthys those are two different settings and the comments in the settings should explain the difference. terminal.external.windowsExec existed before the integrated terminal, it will launch an external terminal (ctrl/cmd+shift+c), terminal.integrated.shell.windows points at a shell which will run inside the integrated terminal.

@meichthys @Tyriar But setting these both keys solved the problem in integrated terminal, not the external

@Riconec It seems like your issue must have been slightly different. I've tried setting both of the mentioned settings explicitly in my user settings to no avail.

I tried all of the suggestions in this post and I still just get the Square white Box in the terminal (like he cursor is in insert mode).

@KevC2 I know it's not ideal, but for now you can downgrade to v1.20 to get the integrated terminal functionality back.
https://code.visualstudio.com/updates/v1_20

Thanks, was hopeful. I back leveled but no go, still does not work. BTW, I am on Windows 10. Works fine for all my co-workers, just not lucky me.

Version 1.20.1
Commit f88bbf9137d24d36d968ea6b2911786bfe103002
Date 2018-02-13T15:34:36.336Z
Shell 1.7.9
Renderer 58.0.3029.110
Node 7.9.0
Architecture x64

I clicked on Help-Toggle Developer Tools, selected Console, then opened a new terminal. I see these messages:
C:\Program Files\Microsoft VS Code\resources\app\node_modules\vscode-xterm\lib\Terminal.js:1482 [Violation] Added non-passive event listener to a scroll-blocking 'wheel' event. Consider marking event handler as 'passive' to make the page more responsive.
C:\Program Files\Microsoft VS Code\resources\app\node_modules\vscode-xterm\lib\Terminal.js:1482 [Violation] Added non-passive event listener to a scroll-blocking 'touchstart' event. Consider marking event handler as 'passive' to make the page more responsive.
C:\Program Files\Microsoft VS Code\resources\app\node_modules\vscode-xterm\lib\Terminal.js:1482 [Violation] Added non-passive event listener to a scroll-blocking 'touchmove' event. Consider marking event handler as 'passive' to make the page more responsive.
actionbar.ts:119 [Violation] 'setTimeout' handler took 117ms

For what it's worth, I see this when I startup VS. I saw something about disabling extensions, so not sure if it's related.
marketplace.visualstudio.com/_apis/public/gallery/extensionquery Failed to load resource: the server responded with a status of 401 (Unauthorized)

I'm having the same issue and have since January. I've tried all the suggestions here and in similar issues but nothing has worked. Currently running 1.22.2 in Windows 10, but I've been having the problem since 1.19.

This issue seems to be fixed _for me_ in 1.23.1
One thing i did before updating was change my default shell to Powershell, so I'm not sure if that had anything to do with the issue being resolved on my VSCode installation.

If anyone is on Insiders and still experiencing this issue could you add this to your settings file, reload and see if that fixes it?

"terminal.integrated.rendererType": "dom"

More details: https://github.com/Microsoft/vscode/issues/46954

Have same issue at vs code 1.23.1 - Window 10

ps: VS Code Insiders 1.24.0 don't have this @issues

Oh, I am looking forward to vs code 1.24

For me (Code v1.24.1 + Win7), the cause of my non-interactive terminal is definitely compatibility mode. Repro is 100%.

As background, I want compatibility mode enabled per the recommendation in #15211 so that the GPU is always disabled without having to use --disable-gpu which would get squashed every time a new version of Code updates my shortcuts. For now, I'll modify my shortcuts.

And the reason I require the GPU disabled is to avoid screen flickering and frequent Nvidia driver restarts, similar to other reports I've seen across OS's, such as #25934, #41513, #41238, #38067, and #21556.

Me Win 10 April Update:

Version 1.24.1
Commit 24f62626b222e9a8313213fb64b10d741a326288
Date 2018-06-13T17:51:32.889Z
Shell 1.7.12
Renderer 58.0.3029.110
Node 7.9.0
Architecture x64

My VSCode is fine. But i can produce error like that:

  1. Using App Better Start menu
  2. Create shortcut via open App using Better Start menu
  3. Open VSCode via Better Start menu
  4. The integrated terminal does not shows...

but, when you open the VSCode normally, it works fine. Maybe it helps... :)

As a temporary solution you can split terminal into 2 or more windows.
image
image

@sergeylaptev hmm. If splitting fixes it, I would also expect resizing the panel/window to fix it too.

Hey guys i solved mine .
After changing the graphic card settings in Nvidia Control Panel.
I changed the Laptop display to Geforce rather than Intel Hd Graphic.
May this help someone/\

I didn't fix the problem, but I got around it. For me, neither bash nor Powershell worked, but cmd did. So in my settings.json, I added
"terminal.integrated.shell.windows": "C:\\Windows\\System32\\cmd.exe", "terminal.integrated.shellArgs.windows": [ "/K", "path\\to\\bash.exe" ]
Now, every time I start up a terminal instance, it will open as cmd then run bash and be usable as bash from then on. It does take it a second to startup, but part of that may be that I had to make a batch script that just runs bash because I couldn't get it to execute bash directly because there's a space in the path to the executable and no amount of quotes and escapes would make it work the right way.

It didn't work for me at first, but I looked at the file path, and I realized I was using the wrong file path. The "Git" folder was inside "Program Files (x86)", but my file path was for "Program Files". Hope that helped! (By the way, I use Windows, so for any other operating system, it's going to be different.)

Have same issue at vs code 1.25.1 - Window 7

terminal.integrated.rendererType set auto , dom, canvas and restart terminal also do not work.

PS:

oh!!! disabling compatibility mode seems to fix it!!!

To solve this problem, just turn off compatibility mode when you are in settings of this file after right mouse click.

I don't know if this is helpful or not, but I notice this mostly when I RDP to my box; almost every time I do, the terminal goes blank (still accepts input, and a small handful of characters still show, though they wouldn't be normal characters people would usually see at a prompt). Ctrl + +, Ctrl + - corrects it for me, but if I leave it, sometimes when I log in locally it will self correct and other times it won't.

I can't seem to replicate it by messing with my color, theme, or resolution settings, unfortunately.

At the moment also running into this issue.
Developer tools show an property 'isWrapped' od undefined error
Screenshot

Pressing enter seems to do something?
Screenshot2

Hi,
I am using msys bash environment with vs code and it was working perfectly till the vs code updated today.

Issue:
workspace configured before vs code update works as expected but the same settings no longer work if new workspace is created now. The bash terminal doesn't show up in integrated terminal

workspace setting:

{
    {
        "workbench.statusBar.visible": true,
        "workbench.activityBar.visible": true,
        "editor.minimap.enabled": false,
        "terminal.integrated.shell.windows": "D:/Workspace/ESP32/toolchain/v3.1/msys32/usr/bin/bash.exe",
        "terminal.integrated.shellArgs.windows": [
            "--login",
        ],
        "terminal.integrated.env.windows": {
            "CHERE_INVOKING": "1",
            "MSYSTEM": "MINGW32",
        },
        "C_Cpp.errorSquiggles": "Disabled",
    }
}

vs code version:

Version: 1.29.1 (system setup)
Commit: bc24f98b5f70467bc689abf41cc5550ca637088e
Date: 2018-11-15T19:13:36.375Z
Electron: 2.0.12
Chrome: 61.0.3163.100
Node.js: 8.9.3
V8: 6.1.534.41
Architecture: x64

Any suggestions on how to fix it?

Updated VS code today and the terminal stopped working. Cannot type anything.

Have same issue at vs code 1.29.1 - Window 10

Anyone got this terminal issue resolved? ☹️

@Tyriar hope you are working on this problems, integrated terminal (at least on windows) in still awfully bad and often barely usable compared to the native one.

I also have this issue with VS Code 1.29.1 on Windows 10. The above fixes didn't work.

I had the exact same issue, more weird is that I could simply press ENTER in the emptyness and the powershell command line would simply shown.

What I have tried and succeed (maybe can help someone):

Digging a bit I've found out that the original terminal.integrated.shell.windows had the wrong path (was pointing to C:\WINDOWS\Sysnative\WindowsPowerShell\v1.0\powershell.exe and that no longer exists, for some reason).

checking the right path for PowerShell I've updated both user and workspace settings to C:\Windows\system32\WindowsPowerShell\v1.0\powershell.exe

changing to bash as the docs mentions I also started to have the terminal in good health:

@balexandre that's #57803 on Windows 10 1809, not Windows 7.

I have this issues as well. I'm using windows and bash\ubuntu WSL for my shell. It's sporadic but happens about 20-30% of the time when I open a terminal. Usually closing the terminal (trash icon) and starting a new one (plus icon) will give me a working terminal.

Same issue here; this is my version:

Version: 1.30.1 (user setup)
Commit: dea8705087adb1b5e5ae1d9123278e178656186a
Date: 2018-12-18T18:12:07.165Z
Electron: 2.0.12
Chrome: 61.0.3163.100
Node.js: 8.9.3
V8: 6.1.534.41
OS: Windows_NT x64 10.0.17763

the terminal (powershell) is blank and the search recent Ctrl+r command stopped working (the console show ^R instead 👎)

Please stop commenting here if you're on Windows 10, you're seeing a bug in Windows that is fixed in the next version #57803.

@Tyriar, are you positive that's the same issue? Based on the description, that's different than the behavior I've seen on Windows 10, and I've not installed 1809 on any of my machines yet.

Add this to your settings.json

"terminal.integrated.shellArgs.windows": ["-NoLogo"]

Wonder if this is related to to the issue. I recently started experiencing an empty terminal on win 10, while pressing enter reveals the prompt. I've noticed that there is a vertical scroll bar. If I make the terminal window large/tall enough(half my screen) then a new terminal shows the prompts as expected without a scroll bar. Not a show stopper, wondering if the experience is similar/repeatable for anyone here.

@dougal83 it's a Windows 10 bug: https://github.com/Microsoft/vscode/issues/57803, press enter once or twice to see your prompt

I have the same problem. My VS Code: 1.30.2 (user setup).

Please stop commenting here if you're on Windows 10, you're seeing a bug in Windows that is fixed in the next version #57803.

How long to wait this next version?

Please stop commenting here if you're on Windows 10, you're seeing a bug in Windows that is fixed in the next version #57803.

版本: 1.31.0 (system setup)
提交: 7c66f58312b48ed8ca4e387ebd9ffe9605332caa
日期: 2019-02-05T22:35:56.624Z
Electron: 3.1.2
Chrome: 66.0.3359.181
Node.js: 10.2.0
V8: 6.6.346.32
OS: Windows_NT x64 10.0.17763

this version not fix

I am on windows 1809 17763.316 The bug is still here.

Will preview versions solve this ?

I think I found a temporary solution!
Step1: Open CMD terminal, edit properties, check this option

Step2: Restart the system

Before:

After:

System Info

Windows 10 1809

VSCode Info

Version: 1.33.1 (user setup)
Commit: 51b0b28134d51361cf996d2f0a1c698247aeabd8
Date: 2019-04-11T08:27:14.102Z
Electron: 3.1.6
Chrome: 66.0.3359.181
Node.js: 10.2.0
V8: 6.6.346.32
OS: Windows_NT x64 10.0.17763

@yw662 I am on v 1809 17763.437 and I have the problem. Both on CMD and Bash (ubuntu 18.04 WSL).

@leslieeilsel - I tried your suggestion and it cause the cmd prompt to crash (Bash is my default).

@devsetgo It seems that this is not a universal solution, let us wait for the official fix.

Also check the terminal.integrated.cwd setting.

I moved computers (from Windows 7 to Windows 10, drives C: and D: to only C:) and terminal stopped working. At first it would exit with code 2, then when I updated today, it would start and freeze with just a white square.

It turns out that my terminal.integrated.cwd setting was set to a folder on D drive, which no longer existed. Changing to to a folder that does exist fixed Terminal.

I think I found a temporary solution!
Step1: Open CMD terminal, edit properties, check this option

Step2: Restart the system

Before:

After:

System Info

Windows 10 1809

VSCode Info

Version: 1.33.1 (user setup)
Commit: 51b0b28
Date: 2019-04-11T08:27:14.102Z
Electron: 3.1.6
Chrome: 66.0.3359.181
Node.js: 10.2.0
V8: 6.6.346.32
OS: Windows_NT x64 10.0.17763

Thanks! This really works!
Below the same window in portuguese:
image

@woshiguabi not the case for me. Even running as admin still doesn't fix it. (On insiders anyway)

Okay so, disabling compatibility mode seems to fix it, regardless of if run is administrator is enabled or not.

@Technoblazed This worked for me, thank you!

@Tyriar, thank you for marking my ticket as duplicate so I could find this thread and devise a Workaround until this is fixed.

ok, I see you are all in windows system. And I have the same question in ubuntu16.04. And when I meet the problem, it can be recovered after reboot the vscode. But it will appear some times later. It is so terrible. Anyone know how to solve it, please tell me. thanks a lot.

ok, I see you are all in windows system. And I have the same question in ubuntu16.04. And when I meet the problem, it can be recovered after reboot the vscode. But it will appear some times later. It is so terrible. Anyone know how to solve it, please tell me. thanks a lot.

^ see if you can access the Properties for Visual Studio Code -> then search through those settings looking for Compatibility options -> Ensure that Visual Studio Code can run as an Administrator, but everything else should be toggled/turn-ed Off.

See if that helps.

There are no plans to invest further in Windows 7 support and the backend that we use for it (winpty), looking forward from Windows 10 1903 we use conpty which is a terminal backend provided by the same team that builds Windows Terminal so we can action such requests much easier.

If you're on WIndows 10 and having issues you're probably seeing #73790 and should uncheck use legacy console in conhost's properties.

This issue is being closed to keep the number of issues in our inbox on a manageable level, we are closing issues that are not going to be addressed in the foreseeable future: We look at the number of votes the issue has received and the number of duplicate issues filed. More details here. If you disagree and feel that this issue is crucial: We are happy to listen and to reconsider.

If you wonder what we are up to, please see our roadmap and issue reporting guidelines.

Thanks for your understanding and happy coding!

Was this page helpful?
0 / 5 - 0 ratings