vscode-php-intellisense icon indicating copy to clipboard operation
vscode-php-intellisense copied to clipboard

Extension keeps focusing the output panel

Open biskyt opened this issue 2 years ago • 3 comments

Whenever this extension generates any output, the VS Code output panel gets focussed. This can get extremely annoying.

A similar issue was fixed in the old PHP IntelliSense vs code extension by felixfbecker, which may give a hint as to how to fix it here: https://github.com/felixfbecker/vscode-php-intellisense/pull/454/files

Although I believe that this extension is forked from there, and so may already include that fix!

Here is a screenshot of the panel I'm talking about. It seems to get opened and focussed every time the language server parses a file...

image

Using the PHP Intellisense extension v1.0.8, with VS Code version: Version: 1.68.0 (user setup) Commit: 4af164ea3a06f701fe3e89a2bcbb421d2026b68f Date: 2022-06-08T11:44:16.822Z Electron: 17.4.7 Chromium: 98.0.4758.141 Node.js: 16.13.0 V8: 9.8.177.13-electron.0 OS: Windows_NT x64 10.0.22621

biskyt avatar Jun 15 '22 15:06 biskyt

The change is over 3 years old, so it has to be in this codebase too. However, what I see is there is an internal error that is causing the LSP to crash. But I do not see an error. Maybe this is causing it to switch over to that tab.

It could be it's running out of memory.

I'll check if that change set is in the code and also what could cause it not to display where the crash is happening.

zobo avatar Jun 15 '22 16:06 zobo

I checked and I have the same versions, but here it does not focus automatically on the PHP Language Server output...

One way to get more information is to set the setting php-intellisense.trace.server to verbose and see the PHP Language Server output. This would reveal what the last LSP messages sent/received were.

zobo avatar Jun 16 '22 04:06 zobo

I looked at the extension code and found why the Output is shown. https://github.com/zobo/vscode-php-intellisense/blob/936828aa0a165bb4d3ef3cc1d2b62709141e1a60/src/extension.ts#L106 As expected it is focused when the LSP server dies unexpectedly.

zobo avatar Jun 16 '22 09:06 zobo