Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VS Code Hangs When Opening Specific PowerShell File #56430

Closed
Mibz opened this issue Aug 15, 2018 · 4 comments
Closed

VS Code Hangs When Opening Specific PowerShell File #56430

Mibz opened this issue Aug 15, 2018 · 4 comments
Assignees
Labels
freeze-slow-crash-leak VS Code crashing, performance, freeze and memory leak issues verified Verification succeeded

Comments

@Mibz
Copy link

Mibz commented Aug 15, 2018

Issue Type: Bug

I am experiencing a problem with VS Code hanging when opening a specific PowerShell file. I think the problem is with the Powershell Language Basics extension, not the Powershell extension, which is why I'm posting here.

When opening the specific script VS Code will hang and eventually I'll receive a prompt saying "The window is no longer responding" and I'm given the option to Reopen, Keep Waiting, or Close.

Reopening the window results in the same behaviour.
Keep Waiting results the same behaviour, though I only clicked it 5-6 times before giving up.
Closing the window works correctly.

If I disable the PowerShell extension and Powershell Language Basics extension, the file loads properly.
If I then re-enable the PowerShell extension and reload, VS Code hangs again.
If I disable the PowerShell extension but leave the Powershell Language Basics extension enabled, the file fails to load.

I can open any other PowerShell file with both extensions enabled, it's just the one file that causes problems. It's 29 KB and ~700 lines. I've tried on two different machines running the same version of Windows, VS Code, and the extensions with no difference in behaviour.

No logs are created in the .vscode\extensions\ms-vscode.powershell-1.8.2\logs folder when this error occurs.

VS Code version: Code 1.26.0 (4e93618, 2018-08-13T16:29:31.933Z)
This was also attempted on 1.27.0-insider with the same results
OS version: Windows_NT x64 10.0.17134

System Info
Item Value
CPUs Intel(R) Core(TM) i7-7700K CPU @ 4.20GHz (8 x 4200)
GPU Status 2d_canvas: enabled
checker_imaging: disabled_off
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
native_gpu_memory_buffers: disabled_software
rasterization: enabled
video_decode: enabled
video_encode: enabled
webgl: enabled
webgl2: enabled
Memory (System) 31.96GB (22.16GB free)
Process Argv removed by reporter
Screen Reader no
VM 0%
Extensions (2)
Extension Author (truncated) Version
PowerShell ms- 1.8.2
vscode-autohotkey sle 0.2.2
@vscodebot
Copy link

vscodebot bot commented Aug 15, 2018

(Experimental duplicate detection)
Thanks for submitting this issue. Please also check if it is already covered by an existing one, like:

@sandy081
Copy link
Member

Could be duplicate of #56368. Issue has the file with which code crashes

@sandy081 sandy081 added the freeze-slow-crash-leak VS Code crashing, performance, freeze and memory leak issues label Aug 15, 2018
@Mibz
Copy link
Author

Mibz commented Aug 15, 2018

Can confirm my behaviour seems identical. I pasted the file from that issue into VS Code without a problem, but once I saved it as .ps1 VS Code hung as it does with my script.

EDIT: I should note that my file is in source control but the fault occurs without using the Source Control window, and without making any changes to the file.

@sandy081 sandy081 assigned aeschli and unassigned alexdima Aug 15, 2018
@sandy081 sandy081 added the candidate Issue identified as probable candidate for fixing in the next release label Aug 15, 2018
@aeschli
Copy link
Contributor

aeschli commented Aug 15, 2018

I reverted the grammar to PowerShell/EditorSyntax@6f54386
where this this file does no longer crash.

@aeschli aeschli added this to the July Recovery 2018 milestone Aug 15, 2018
@sandy081 sandy081 added the verified Verification succeeded label Aug 16, 2018
@egamma egamma removed the candidate Issue identified as probable candidate for fixing in the next release label Aug 17, 2018
@vscodebot vscodebot bot locked and limited conversation to collaborators Sep 29, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
freeze-slow-crash-leak VS Code crashing, performance, freeze and memory leak issues verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

5 participants