Vscode-powershell: [Preview-2020.2.0] F5 works only once

Created on 23 Feb 2020  路  7Comments  路  Source: PowerShell/vscode-powershell

Issue Type: Bug

Setup:

Preview-2020.2.0 + PS7
(Do not create launch.json)

Steps to reproduce:

  1. F5 (file will run)
  2. F5 (debugger will start and do nothing)

F5
EditorServices.log
Extension version: 2020.2.0
VS Code version: Code 1.42.1 (c47d83b293181d9be64f27ff093689e8e7aed054, 2020-02-11T14:45:59.656Z)
OS version: Windows_NT x64 10.0.18363


System Info

|Item|Value|
|---|---|
|CPUs|AMD Ryzen 7 1800X Eight-Core Processor (4 x 3593)|
|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: unavailable_off
rasterization: unavailable_off
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)|4.00GB (1.57GB free)|
|Process Argv||
|Screen Reader|no|
|VM|100%|


Area-Debugging Issue-Bug Resolution-Fixed

Most helpful comment

It happens with and without workspace.
I tested it only on windows.
Hitting enter or Ctrl+C between F5s actually prevent the problem.
Maybe another clue after the second F5 if I F6 to pause it stops on a temporary AppData\Local\Temp\PSES-2376\[ILI] Script Listing.ps1 script with only 0 in it.

All 7 comments

@ili101 do you have any workspace open?

I've tried this on PS6 and PS7 and can't repro the behavior you're seeing. The only difference right now is that I'm on macOS and you're on Windows.

Also as a troubleshooting step, if you hit enter in the console before hitting F5 a second time, does that work?

It happens with and without workspace.
I tested it only on windows.
Hitting enter or Ctrl+C between F5s actually prevent the problem.
Maybe another clue after the second F5 if I F6 to pause it stops on a temporary AppData\Local\Temp\PSES-2376\[ILI] Script Listing.ps1 script with only 0 in it.

That's really great information @ili101. Thank you!

I was unable to repro this on Windows, however, I did reproduce this on @SydneyhSmith 's machine.

It seems to happen when a machine is totally bogged down and so the PowerShell extension runs very slowly and gets into some bad state.

Still investigating...

I'm able to reproduce when I comment out my personal changes to the prompt function.

This seems to have the same root cause as https://github.com/PowerShell/vscode-powershell/issues/2364

I think I'm having the same issue. The code never finishes execution and the debug pop-up at the top stays. Quitting it is not always possible, so I'm forced to kill the terminal and restart it. It might be related but code unfolding is also no longer possible in some cases. Thank you for looking in to this nasty little bug.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

daviwil picture daviwil  路  3Comments

daviwil picture daviwil  路  4Comments

rkeithhill picture rkeithhill  路  3Comments

CJHarmath picture CJHarmath  路  3Comments

TheDanishDynamo picture TheDanishDynamo  路  3Comments