Closed SetTrend closed 5 years ago
The particular syntax you're using there isn't valid PowerShell; a function can take a param block or it can take a parameter list in parens, but not param
inside a parameter list.
How about something like:
In this case though, you're still in an empty file and most of what you're writing are either keywords or parameter names.
We get our completions from PowerShell and it doesn't provide keyword completions. Nor does it provide parameter name suggestions or untyped hashtable key/value suggestions. Basically, in the scenario you've got, things are still wide open, so there are no completions to provide.
Do you get completions on Get-<TAB>
?
To me it looks like there is some random condition that's keeping PowerShell IntelliSense from providing results in a timely manner.
Look at this screencast I just recorded:
Typing get
the first time brought up IntelliSense information right away. I didn't even have to hit the TAB key for auto-completion to appear.
Then, after deleting my line, hitting get-
TAB didn't yield any result for a very long period of time. After that, auto-completion by typing get
didn't work anymore and typing get-
TAB kept taking a very long period of time.
Yes, this is a performance issue in the current stable PowerShell extension. It's improved in the preview extension, and we think the next release of the preview extension will have significant improvements here.
You can try the preview extension by uninstalling the powershell
extension and then installing powershell-preview
.
We've also committed to getting these improvements into the stable channel in January, so this should be improved over the course of the next few months.
Going to mark this as a duplicate of https://github.com/PowerShell/vscode-powershell/issues/647
This issue has been marked as duplicate and has not had any activity for 1 day. It has been closed for housekeeping purposes.
Issue Description
I am experiencing a problem with IntelliSense. It doesn't auto-complete whatsoever:
Attached Logs
Follow the instructions in the README about capturing and sending logs.
The link points to no README (404).
EditorService.log
``` 24.10.2019 12:11:50 [NORMAL] - Path specified by 'powerShellExePath' setting - '' - not found, reverting to default PowerShell path. 24.10.2019 12:11:50 [NORMAL] - Language server starting -- 24.10.2019 12:11:50 [NORMAL] - exe: C:\Program Files\PowerShell\6\pwsh.exe 24.10.2019 12:11:50 [NORMAL] - args: c:\Users\oizdax\.vscode\extensions\ms-vscode.powershell-2019.9.0\modules\PowerShellEditorServices\Start-EditorServices.ps1 -HostName 'Visual Studio Code Host' -HostProfileId 'Microsoft.VSCode' -HostVersion '2019.9.0' -AdditionalModules @('PowerShellEditorServices.VSCode') -BundledModulesPath 'c:\Users\oizdax\.vscode\extensions\ms-vscode.powershell-2019.9.0\modules' -EnableConsoleRepl -LogLevel 'Normal' -LogPath 'c:\Users\oizdax\.vscode\extensions\ms-vscode.powershell-2019.9.0\logs\1571911910-51fe49cb-c464-4f6a-ab4a-1c5e90b560d51571911148040\EditorServices.log' -SessionDetailsPath 'c:\Users\oizdax\.vscode\extensions\ms-vscode.powershell-2019.9.0\sessions\PSES-VSCode-8056-646319' -FeatureFlags @() 24.10.2019 12:11:51 [NORMAL] - powershell.exe started, pid: 15776 24.10.2019 12:11:52 [NORMAL] - Language server started. 24.10.2019 12:11:52 [NORMAL] - {"status":"started","debugServicePipeName":"\\\\.\\pipe\\PSES_rspucd1q.sn4","languageServiceTransport":"NamedPipe","languageServicePipeName":"\\\\.\\pipe\\PSES_e4dkj0ow.i0e","debugServiceTransport":"NamedPipe"} 24.10.2019 12:11:52 [NORMAL] - Connecting to language service on pipe \\.\pipe\PSES_e4dkj0ow.i0e... 24.10.2019 12:11:52 [NORMAL] - Language service connected. ```vscode-powershell.log
``` 2019-10-24 12:11:52.192 [NORMAL] tid:10 in 'StartLogging' D:\a\1\s\src\PowerShellEditorServices.Host\EditorServicesHost.cs: line 183 PowerShell Editor Services Host v1.13.0.0 starting (PID 15776 Host application details: Name: Visual Studio Code Host Version: 2019.9.0 ProfileId: Microsoft.VSCode Arch: X64 Operating system details: Version: Microsoft Windows 10.0.17763 Arch: X64 Build information: Version: Origin: VSTS Date: 2019-09-20T23:36:27 2019-10-24 12:11:52.217 [NORMAL] tid:10 in 'StartLanguageService' D:\a\1\s\src\PowerShellEditorServices.Host\EditorServicesHost.cs: line 202 Language service started, type = NamedPipe, endpoint = InOut pipe: PSES_e4dkj0ow.i0e 2019-10-24 12:11:52.225 [NORMAL] tid:10 in 'StartDebugService' D:\a\1\s\src\PowerShellEditorServices.Host\EditorServicesHost.cs: line 279 Debug service started, type = NamedPipe, endpoint = InOut pipe: PSES_rspucd1q.sn4 2019-10-24 12:11:52.739 [NORMAL] tid:7 in 'Initialize' D:\a\1\s\src\PowerShellEditorServices\Session\PowerShellContext.cs: line 221 PowerShell runtime version: 6.2.3, edition: Core 2019-10-24 12:11:53.497 [ERROR] tid:16 in 'ExecuteCommand' D:\a\1\s\src\PowerShellEditorServices\Session\PowerShellContext.cs: line 565 Execution of the following command(s) completed with errors: Import-Module C:\Users\oizdax\.vscode\extensions\ms-vscode.powershell-2019.9.0\modules\PowerShellEditorServices\bin\Core\..\..\Commands\PowerShellEditorServices.Commands.psd1 2019-10-24 12:11:53.559 [NORMAL] tid:20 in 'Register' D:\a\1\s\src\PowerShellEditorServices.VSCode\ComponentRegistration.cs: line 36 PowerShell Editor Services VS Code module loaded. ```Environment Information
Visual Studio Code
PowerShell Information
Visual Studio Code Extensions
Visual Studio Code Extensions(Click to Expand)
|Extension|Author|Version| |---|---|---| |classic-asp|ilich8086|0.0.4| |debugger-for-chrome|msjsdiag|4.12.0| |lit-html|bierner|1.11.1| |powershell|ms-vscode|2019.9.0| |vscode-hexdump|slevesque|1.7.2| |vscode-language-pack-de|MS-CEINTL|1.39.3| |xml-format|mikeburgh|1.0.2|