question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

VSCode UI locks up occassionally when using "Powershell: Restart Current Session"

See original GitHub issue

Issue Description

VSCode locks up on occasion when using powershell: restart session. It looks like it happens before the PSES loads. No debug was used in this attempt.

image

Attached Logs

Follow the instructions in the README about capturing and sending logs.

Environment Information

Visual Studio Code

Name Version
Operating System Windows_NT x64 10.0.19041
VSCode 1.42.0-insider
PowerShell Extension Version 2019.12.0

PowerShell Information

Name Value
PSVersion 5.1.19041.1
PSEdition Desktop
PSCompatibleVersions 1.0 2.0 3.0 4.0 5.0 5.1.19041.1
BuildVersion 10.0.19041.1
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1

##Issue Type: Performance Issue

Latest Powershell Preview: Use the command “Powershell: Restart Current Session”. The freezing is intermittent but I have been able to reproduce on two separate computers now.

Extension version: 2019.12.0 VS Code version: Code - Insiders 1.42.0-insider (241d4048aabc31db0baed66bb3d58cf3210d981d, 2019-12-17T10:43:45.626Z) OS version: Windows_NT x64 10.0.19041

System Info
Item Value
CPUs Intel® Core™ i5-1035G7 CPU @ 1.20GHz (8 x 1498)
GPU Status 2d_canvas: enabled
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
metal: disabled_off
multiple_raster_threads: enabled_on
oop_rasterization: disabled_off
protected_video_decode: enabled
rasterization: enabled
skia_renderer: disabled_off
surface_control: disabled_off
surface_synchronization: enabled_on
video_decode: enabled
viz_display_compositor: enabled_on
viz_hit_test_surface_layer: disabled_off
webgl: enabled
webgl2: enabled
Load (avg) undefined
Memory (System) 7.60GB (1.49GB free)
Process Argv –folder-uri file:///c%3A/Users/jgrote/Projects/CredDriveGist/97fe1269f17d471191a08610fe71b956
Screen Reader no
VM 0%
Process Info
CPU %	Mem MB	   PID	Process
    1	   116	 13408	code-insiders main
    0	   222	  9032	   window (Untitled-1 - 97fe1269f17d471191a08610fe71b956 - Visual Studio Code - Insiders)
    0	    15	  1520	     watcherService 
    0	    11	  6092	       console-window-host (Windows internal process)
    0	     6	 10580	     console-window-host (Windows internal process)
    0	   138	 10960	     C:\WINDOWS\System32\WindowsPowerShell\v1.0\powershell.exe -NoProfile -NonInteractive -ExecutionPolicy Bypass -Command "Import-Module 'c:\Users\jgrote\.vscode-insiders\extensions\ms-vscode.powershell-preview-2019.12.0\modules\PowerShellEditorServices\PowerShellEditorServices.psd1'; Start-EditorServices -HostName 'Visual Studio Code Host' -HostProfileId 'Microsoft.VSCode' -HostVersion '2019.12.0' -AdditionalModules @('PowerShellEditorServices.VSCode') -BundledModulesPath 'c:\Users\jgrote\.vscode-insiders\extensions\ms-vscode.powershell-preview-2019.12.0\modules' -EnableConsoleRepl -LogLevel 'Normal' -LogPath 'c:\Users\jgrote\.vscode-insiders\extensions\ms-vscode.powershell-preview-2019.12.0\logs\1576688022-5d54cd62-c730-4487-bd08-747a9bd419e61576688019997\EditorServices.log' -SessionDetailsPath 'c:\Users\jgrote\.vscode-insiders\extensions\ms-vscode.powershell-preview-2019.12.0\sessions\PSES-VSCode-13408-997449' -FeatureFlags @() "
    0	    86	 10976	     pwsh.exe -nologo
    0	   135	 14120	     extensionHost
    0	    72	 14296	     searchService
    0	     6	 15512	     console-window-host (Windows internal process)
    0	    86	 10884	   window (Issue Reporter)
    0	     7	 12116	   C:\Users\jgrote\AppData\Local\Temp\vscode-update-user-x64\CodeSetup-insider-26f5dfcd76c9a02f116a706844611aeb09ae8c0b.exe /verysilent /update="C:\Users\jgrote\AppData\Local\Temp\vscode-update-user-x64\CodeSetup-insider-26f5dfcd76c9a02f116a706844611aeb09ae8c0b.flag" /nocloseapplications /mergetasks=runcode,!desktopicon,!quicklaunchicon
    0	    22	 12104	     "C:\Users\jgrote\AppData\Local\Temp\is-VT9TQ.tmp\CodeSetup-insider-26f5dfcd76c9a02f116a706844611aeb09ae8c0b.tmp" /SL5="$30662,58711380,168448,C:\Users\jgrote\AppData\Local\Temp\vscode-update-user-x64\CodeSetup-insider-26f5dfcd76c9a02f116a706844611aeb09ae8c0b.exe" /verysilent /update="C:\Users\jgrote\AppData\Local\Temp\vscode-update-user-x64\CodeSetup-insider-26f5dfcd76c9a02f116a706844611aeb09ae8c0b.flag" /nocloseapplications /mergetasks=runcode,!desktopicon,!quicklaunchicon
    2	   261	 14192	   gpu-process
    1	   178	 14760	   window (EditorServices.log - 1576688022-5d54cd62-c730-4487-bd08-747a9bd419e61576688019997 - Visual Studio Code - Insiders)
    0	    73	  9372	     searchService
    0	   126	 12912	     extensionHost
    0	    15	 14976	     watcherService 
    0	    11	 14004	       console-window-host (Windows internal process)
    0	    54	 15252	   electron-crash-reporter
    0	    88	 15368	   shared-process
Workspace Info
|  Window (Untitled-1 - 97fe1269f17d471191a08610fe71b956 - Visual Studio Code - Insiders)
|  Window (EditorServices.log - 1576688022-5d54cd62-c730-4487-bd08-747a9bd419e61576688019997 - Visual Studio Code - Insiders)
|    Folder (1576688022-5d54cd62-c730-4487-bd08-747a9bd419e61576688019997): 3 files
|      File types: log(3)
|      Conf files:
|    Folder (97fe1269f17d471191a08610fe71b956): 5 files
|      File types: psm1(1) ps1xml(1) dll(1) ps1(1)
|      Conf files:;

Visual Studio Code Extensions

Visual Studio Code Extensions(Click to Expand)
Extension Author Version
better-align wwm 1.1.6
better-comments aaron-bond 2.0.5
better-powershell-syntax-highlighting justin-grote 0.0.2
bracket-pair-colorizer-2 CoenraadS 0.0.29
code-settings-sync Shan 3.4.3
gc-excelviewer GrapeCity 2.1.32
gistfs vsls-contrib 0.0.21
git-graph mhutchie 1.19.1
gitlens eamodio 10.2.0
indent-rainbow oderwat 7.4.0
markdown-all-in-one yzhang 2.6.1
powershell-preview ms-vscode 2019.12.0
remote-containers ms-vscode-remote 0.96.0
remote-ssh-edit-nightly ms-vscode-remote 2019.12.24000
remote-ssh-nightly ms-vscode-remote 2019.12.24000
remote-wsl ms-vscode-remote 0.41.6
todo-tree Gruntfuggly 0.0.162
vscode-icons vscode-icons-team 9.6.0
vscode-peacock johnpapa 3.2.0
vscode-sort-json richie5um2 1.18.0
vscode-zipexplorer slevesque 0.3.1

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:9
  • Comments:79 (22 by maintainers)

github_iconTop GitHub Comments

10reactions
Tyriarcommented, Jun 9, 2020

@JustinGrote I just tested in VS Code and it works, I need to figure out how to bring it in though as there are complications around using worker_threads in Electron https://github.com/microsoft/node-pty/pull/415#issuecomment-641415513

3reactions
JustinGrotecommented, Feb 10, 2021

This is likely fixed by https://github.com/microsoft/vscode/pull/116185

Which should land in insiders within the next week. Fingers crossed.

Read more comments on GitHub >

github_iconTop Results From Across the Web

VsCode hangs/freezes with "Starting up powershell" in status ...
Start VsCode running as Admin. That will complete the "Starting Powerhell" and in the status bar you will see the Powershell version.
Read more >
Remote Development Tips and Tricks - Visual Studio Code
This article covers troubleshooting tips and tricks for each of the Visual Studio Code Remote Development extensions. See the SSH, Containers, and WSL...
Read more >
PowerShell editing with Visual Studio Code
Learn about using PowerShell in Visual Studio Code. ... The extension works anywhere you can run VS Code and PowerShell 7 or higher....
Read more >
February 2021 (version 1.54) - Visual Studio Code
This setting is useful for PowerShell debugging since the PowerShell debugger supports debugging unsaved files. Improved Enablement for Restart Frame action.
Read more >
November 2022 (version 1.74) - Visual Studio Code
Hide Activity bar and Panel badges - Simplify the editor UI by toggling ... The Restart command in the debug toolbar restarts the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found