You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Outline says No Symbols Found for the current doc. start type and symbols appear #1852
I opened existing file that had problem before. Same problem as 2334. Hit space and symbols appear.
Cut and paste all code from that file to new file, saved and closed new file. On open of new file, symbols appear. On Open of old file with identical code no symbols until hit space.
Environment data
VS Code version: 1.27.1
Extension version (available under the Extensions sidebar): 2018.8.0
OS and version: Ubuntu 16.04.3
Python version (& distribution if applicable, e.g. Anaconda): 3.5.2
Type of virtual environment used (N/A | venv | virtualenv | conda | ...): N/A
Relevant/affected Python packages and their versions: N/A
Actual behavior
Outline view does not display any symbols after file open. Outline view shows 'No symbols found in document xxx'. On editing the file symbols appear in couple of seconds
Expected behavior
Symbols appear in outline window after opening file
changed the title [-]Language Server: Variant of 2334: Outline says No Symbols Found for the current doc. start type and symbols appear[/-][+]Outline says No Symbols Found for the current doc. start type and symbols appear[/+]on Sep 10, 2018
I'm not clear what info you are looking for. There are multiple options in the output panel. The python option shows, however I dont think this is what you are after:
##########Linting Output - pylint##########
************* Module inline_shared
24,4,warning,W0602:Using global for 'registers_file' but no assignment is done
25,4,warning,W0602:Using global for 'interfaces_file' but no assignment is done
26,4,warning,W0602:Using global for 'memories_file' but no assignment is done
27,4,warning,W0602:Using global for 'top' but no assignment is done
28,4,warning,W0602:Using global for 'ymldir' but no assignment is done
30,4,warning,W0602:Using global for 'ifYaml' but no assignment is done
31,4,warning,W0602:Using global for 'structYaml' but no assignment is done
32,4,warning,W0602:Using global for 'top_file' but no assignment is done
35,27,error,E0602:Undefined variable 'top_file'
Your code has been rated at 6.29/10 (previous run: 6.29/10, +0.00)
There should be a line saying Starting Microsoft Python language server. and then a line about Initializing. I'm trying to make sure there are not any error messages and that the language server is ready running and done analyzing.
I installed the new extension. My MS python extension reports 2108.9.0-Alpha
I reverted the fix provided before by setting python.jediEnabled: True
Behavior is the same as when I filed the bug.
See output window:
Starting Jedi Python language engine.
##########Linting Output - pylint##########
************* Module inline_shared
24,4,warning,W0602:Using global for 'registers_file' but no assignment is done
25,4,warning,W0602:Using global for 'interfaces_file' but no assignment is done
26,4,warning,W0602:Using global for 'memories_file' but no assignment is done
27,4,warning,W0602:Using global for 'top' but no assignment is done
28,4,warning,W0602:Using global for 'ymldir' but no assignment is done
30,4,warning,W0602:Using global for 'ifYaml' but no assignment is done
31,4,warning,W0602:Using global for 'structYaml' but no assignment is done
32,4,warning,W0602:Using global for 'top_file' but no assignment is done
35,27,error,E0602:Undefined variable 'top_file'
------------------------------------------------------------------
Your code has been rated at 6.29/10 (previous run: 6.29/10, +0.00)
Re-enabled the workaround by disabling jediEnabled
Starting Microsoft Python language server.
Downloading https://pvsc.blob.core.windows.net/python-language-server/Python-Language-Server-linux-x64.0.1.0.nupkg... complete.Unpacking archive... done.
Initializing for /usr/bin/python3
##########Linting Output - pylint##########
************* Module inline_shared
24,4,warning,W0602:Using global for 'registers_file' but no assignment is done
25,4,warning,W0602:Using global for 'interfaces_file' but no assignment is done
26,4,warning,W0602:Using global for 'memories_file' but no assignment is done
27,4,warning,W0602:Using global for 'top' but no assignment is done
28,4,warning,W0602:Using global for 'ymldir' but no assignment is done
30,4,warning,W0602:Using global for 'ifYaml' but no assignment is done
31,4,warning,W0602:Using global for 'structYaml' but no assignment is done
32,4,warning,W0602:Using global for 'top_file' but no assignment is done
35,27,error,E0602:Undefined variable 'top_file'
------------------------------------------------------------------
Your code has been rated at 6.29/10 (previous run: 6.29/10, +0.00)
Symbols appear correctly. As they did before updating the ms-python engine.
I have the sense that there is some confusion here. You asked me to update the ms-python, but I think that was working before. My understand - which could be incorrect is that you have two engines
ms-python and jedi
Jedi is not working, ms-python is.
Going forward the new (still experimental) Microsoft Language Server will be the default language server for intelliense and related.
So, my suggestion is to use Language Server going forward (as that's where you'll get the best experience), e.g. this is a good example.
I don't dont have docker nor Gitlens.
When I have Pylance enabled and start typing outline gets populated.
After I disable Pylance and reload, start typing, outline remains empty. (I still have intelli sense though)
So looks like Pylance makes it work, but only on trigger, I would expect it to work without Pylance.
Brett Cannon (@brettcannon) Our side is #1823 (so I guess I could close this as a dupe), but as far as I'm concerned, issues with the outline only appearing after typing are squarely in the client or VS Code's domain and need to be fixed there. We don't even get the request for the outline when this happens.
We're only at the stage where we need to reproduce this and then debug it in the Python extension to see.
I am on version 1.87 (February 2024) and experience the same problem.
In outline, it always shows "no symbols found for file.py"
All consoles (problems, output, terminal ) are empty.
I am on RHEL8, projecting UI using X. (no code server etc)
dbabits, this issue has been closed for a long time. Please open a new one. If you're really not seeing anything in the output pane, not just under Python Language Server, but in any of the logs, I'd guess that this is a VS Code issue rather than a Pylance issue, so I'd suggest opening it here: https://github.com/microsoft/vscode/issues
Activity
[-]Language Server: Variant of 2334: Outline says No Symbols Found for the current doc. start type and symbols appear[/-][+]Outline says No Symbols Found for the current doc. start type and symbols appear[/+]brettcannon commentedon Sep 10, 2018
What does the Output panel say for the language server? I want to make sure that it has completed starting as you left out what the panel says.
atomlin commentedon Sep 10, 2018
I'm not clear what info you are looking for. There are multiple options in the output panel. The python option shows, however I dont think this is what you are after:
##########Linting Output - pylint##########
************* Module inline_shared
24,4,warning,W0602:Using global for 'registers_file' but no assignment is done
25,4,warning,W0602:Using global for 'interfaces_file' but no assignment is done
26,4,warning,W0602:Using global for 'memories_file' but no assignment is done
27,4,warning,W0602:Using global for 'top' but no assignment is done
28,4,warning,W0602:Using global for 'ymldir' but no assignment is done
30,4,warning,W0602:Using global for 'ifYaml' but no assignment is done
31,4,warning,W0602:Using global for 'structYaml' but no assignment is done
32,4,warning,W0602:Using global for 'top_file' but no assignment is done
35,27,error,E0602:Undefined variable 'top_file'
Your code has been rated at 6.29/10 (previous run: 6.29/10, +0.00)
brettcannon commentedon Sep 10, 2018
There should be a line saying
Starting Microsoft Python language server.and then a line aboutInitializing. I'm trying to make sure there are not any error messages and that the language server is ready running and done analyzing.atomlin commentedon Sep 10, 2018
Restarted code. In the python window I see
Starting Jedi Python language engine.In Log (Extension Host)
brettcannon commentedon Sep 11, 2018
Andy Tomlin (@atomlin) Thanks! Helps clarify things that this is due to Jedi.
atomlin commentedon Sep 13, 2018
Is there a workaround?
d3r3kk commentedon Sep 13, 2018
Can you try switching to the new Python Language Server and see if that helps? In your settings, set
"python.jediEnabled": falseand restart VSCode.atomlin commentedon Sep 13, 2018
Ok, that worked.
DonJayamanne commentedon Sep 20, 2018
I can confirm this works in the latest development environment.
Andy Tomlin (@atomlin)
Please could you install the development version of the extension and test this out. Should work now.
Here are the instructions to download and install the development version of the extension: https://github.com/Microsoft/vscode-python/blob/master/CONTRIBUTING.md#development-build
atomlin commentedon Sep 20, 2018
I installed the new extension. My MS python extension reports 2108.9.0-Alpha
I reverted the fix provided before by setting python.jediEnabled: True
Behavior is the same as when I filed the bug.
See output window:
Re-enabled the workaround by disabling jediEnabled
Symbols appear correctly. As they did before updating the ms-python engine.
I have the sense that there is some confusion here. You asked me to update the ms-python, but I think that was working before. My understand - which could be incorrect is that you have two engines
ms-python and jedi
Jedi is not working, ms-python is.
DonJayamanne commentedon Sep 20, 2018
Going forward the new (still
experimental) Microsoft Language Server will be the default language server for intelliense and related.So, my suggestion is to use
Language Servergoing forward (as that's where you'll get the best experience), e.g. this is a good example.21 remaining items
jamilraichouni commentedon Mar 29, 2021
Can confirm this issue using Pylance and having GitLens extension disabled.
Version: 1.55.0-insider
Commit: d06d2f1d6245ce00b1c36a9cd81a9087d225173e
Date: 2021-03-26T13:57:45.993Z
Electron: 11.3.0
Chrome: 87.0.4280.141
Node.js: 12.18.3
V8: 8.7.220.31-electron.0
OS: Darwin x64 20.3.0
Python extension:
v2021.4.690665134-dev
Pylance extension:
v2021.3.4-pre.1
Global user settings:
{ (...) "python.languageServer": "Pylance" (...) }mrx23dot commentedon Sep 15, 2021
Same issue for me,
I don't dont have docker nor Gitlens.
When I have Pylance enabled and start typing outline gets populated.
After I disable Pylance and reload, start typing, outline remains empty. (I still have intelli sense though)
So looks like Pylance makes it work, but only on trigger, I would expect it to work without Pylance.
Still no fix after 3years?
brettcannon commentedon Sep 21, 2021
This is fixed in Jedi behind LSP (just a bit slow; you must wait for the extension and Jedi to fully load). Transferring to Pylance for their side.
Mathieu Moreau (@mrx23dot) Pylance is only 15 months old.
jakebailey commentedon Sep 21, 2021
Brett Cannon (@brettcannon) Our side is #1823 (so I guess I could close this as a dupe), but as far as I'm concerned, issues with the outline only appearing after typing are squarely in the client or VS Code's domain and need to be fixed there. We don't even get the request for the outline when this happens.
We're only at the stage where we need to reproduce this and then debug it in the Python extension to see.
Corallus-Caninus commentedon Feb 28, 2022
Same issue as of now for rust-analyzer language server.
jovylle commentedon Oct 1, 2022
Yeah, how to view it.
dbabits commentedon Apr 11, 2024
I am on version 1.87 (February 2024) and experience the same problem.
In outline, it always shows "no symbols found for file.py"
All consoles (problems, output, terminal ) are empty.
I am on RHEL8, projecting UI using X. (no code server etc)
debonte commentedon Apr 11, 2024
dbabits, this issue has been closed for a long time. Please open a new one. If you're really not seeing anything in the output pane, not just under Python Language Server, but in any of the logs, I'd guess that this is a VS Code issue rather than a Pylance issue, so I'd suggest opening it here: https://github.com/microsoft/vscode/issues