Skip to content

IntelliSense broken #2253

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

Closed
SetTrend opened this issue Oct 24, 2019 · 5 comments
Closed

IntelliSense broken #2253

SetTrend opened this issue Oct 24, 2019 · 5 comments
Labels
Area-IntelliSense Issue-Bug A bug to squash. Resolution-Duplicate Will close automatically.

Comments

@SetTrend
Copy link

SetTrend commented Oct 24, 2019

Issue Description

I am experiencing a problem with IntelliSense. It doesn't auto-complete whatsoever:

PowerShell IntelliSense

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

Name Version
Operating System Windows_NT x64 10.0.17763
VSCode 1.39.2
PowerShell Extension Version 2019.9.0

PowerShell Information

Name Value
PSVersion 6.2.3
PSEdition Core
GitCommitId 6.2.3
OS Microsoft Windows 10.0.17763
Platform Win32NT
PSCompatibleVersions 1.0 2.0 3.0 4.0 5.0 5.1.10032.0 6.2.3
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0

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
@ghost ghost added the Needs: Triage Maintainer attention needed! label Oct 24, 2019
@rjmholt
Copy link
Contributor

rjmholt commented Oct 24, 2019

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:

validps

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>?

@SydneyhSmith SydneyhSmith added Needs-Repro-Info and removed Needs: Triage Maintainer attention needed! labels Oct 24, 2019
@SetTrend
Copy link
Author

SetTrend commented Oct 28, 2019

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:

PowerShell IntelliSense 2

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.

@ghost ghost added the Needs: Maintainer Attention Maintainer attention needed! label Oct 28, 2019
@rjmholt
Copy link
Contributor

rjmholt commented Oct 28, 2019

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.

@SydneyhSmith SydneyhSmith added Area-IntelliSense Issue-Bug A bug to squash. and removed Needs-Repro-Info Needs: Maintainer Attention Maintainer attention needed! labels Oct 28, 2019
@rjmholt
Copy link
Contributor

rjmholt commented Oct 28, 2019

Going to mark this as a duplicate of #647

@rjmholt rjmholt added the Resolution-Duplicate Will close automatically. label Oct 28, 2019
@ghost
Copy link

ghost commented Oct 29, 2019

This issue has been marked as duplicate and has not had any activity for 1 day. It has been closed for housekeeping purposes.

@ghost ghost closed this as completed Oct 29, 2019
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-IntelliSense Issue-Bug A bug to squash. Resolution-Duplicate Will close automatically.
Projects
None yet
Development

No branches or pull requests

3 participants