Skip to content

integrated console starts immediately if untitled editor is reloaded #1420

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

Open
msftrncs opened this issue Jul 11, 2018 · 6 comments
Open

integrated console starts immediately if untitled editor is reloaded #1420

msftrncs opened this issue Jul 11, 2018 · 6 comments
Labels
Area-Extension Terminal Issue-Enhancement A feature request (enhancement).

Comments

@msftrncs
Copy link

Issue Type: Bug

Start VSCode with PowerShell extension enabled, with an untitled and dirty PowerShell editor reloaded from hot-exit, but not restarted with the focus (so other editors that are not PowerShell must be also reloaded from hot-exit), and the PowerShell integrated console starts immediately (as soon as extensions start), with its 'starting' status and later the icon appearing in the status bar, even though its unwarranted. This only seems to happen while there is an untitled PowerShell language mode editor that is also dirty, restarted via hot-exit, without it being in focus. (Integrated console starting is expected if any editor in PowerShell language mode restarts with the focus)

image

image

Examples above are with an also untitled dirty SQL language file reloaded with the focus. I can however confirm that it also occurs if a saved and not dirty file is reloaded with the focus, such as Batch:

image

Extension version: 1.8.0
VS Code version: Code 1.25.0 (0f080e5267e829de46638128001aeb7ca2d6d50e, 2018-07-05T13:11:58.697Z)
OS version: Windows_NT x64 10.0.17134

System Info
Item Value
CPUs Intel(R) Core(TM) i5 CPU U 430 @ 1.20GHz (4 x 1197)
GPU Status 2d_canvas: enabled
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: unavailable_software
video_decode: enabled
video_encode: enabled
vpx_decode: unavailable_software
webgl: enabled
webgl2: enabled
Memory (System) 1.74GB (0.66GB free)
Process Argv C:\Program Files\Microsoft VS Code\Code.exe
Screen Reader no
VM 0%
@msftrncs
Copy link
Author

Reference to my original mention of this issue on VS Code:
microsoft/vscode#53643

@rkeithhill
Copy link
Contributor

rkeithhill commented Jul 15, 2018

What exactly is the bug? Is it that the PowerShell extension is started upon VSCode restart from a hot exit with an untitled PowerShell editor (with text) that is open but not active (not focused)? I can repro that. But, as you suspect in your vscode issue, it is VSCode that is choosing to activate the PowerShell extension in this case. I'm not sure there is a bug in this extension.

That said, I'm still not quite why you think it is unwarranted? You do have an editor open with PowerShell content in it.

@msftrncs
Copy link
Author

msftrncs commented Jul 17, 2018

because it simply doesn't happen if there are no untitled dirty editors that start as part of the hot-exit. That makes it an abnormal behavior. During normal operations the PowerShell icon only appears while an editor set to PowerShell language mode has focus, and it only starts after the first PowerShell editor has received focus after the start up. As small and unimportant as this is, its still a bug, that it behaves differently under the conditions of an untitled dirty PowerShell mode editor.

Oh, and if this was fixed (as a VS Code issue), it probably also would fix the MSSQL extension issue that was at the heart of my original issue.

@rjmholt rjmholt added Issue-Enhancement A feature request (enhancement). Area-Extension Terminal labels Jul 31, 2018
@viloun
Copy link

viloun commented Dec 11, 2018

I think this is the bug that I ran into. If I have an "Untitled-1" file and mark it as Powershell, then the "Powershell Integrated Console" crashes, and it never returns. This means that I can no longer use the Debug and the status always says "Starting PowerShell..." and it never starts up. If I remove the "Untitled-1" temp file and restart vscode, then everything behaves normally.

My environment:

VSCode version: 1.29.1 bc24f98b5f70467bc689abf41cc5550ca637088e x64

VSCode extensions:

[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]

PSES version: 1.10.1.0

PowerShell version:

Name Value


PSVersion 5.1.14393.693
PSEdition Desktop
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 10.0.14393.693
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1

@rjmholt
Copy link
Contributor

rjmholt commented Dec 11, 2018

@viloun that sounds like a separate bug. Can you open a new issue and attach your logs please? The information to do so will be in the bug template

@viloun
Copy link

viloun commented Dec 12, 2018

It's opened here: #1649

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Extension Terminal Issue-Enhancement A feature request (enhancement).
Projects
None yet
Development

No branches or pull requests

4 participants