Open hlouzada opened 3 years ago
Hi @hlouzada,
We definitely need to add this to Spyder 's client for it to work. If you are interested in helping us with this enhancement, we could give you all the guidance you need.
Thanks for reporting!
Hi @steff456,
I would be delighted to help, but currently, I don't have enough time available and, as it's not critical for my Language Server project, it'll have to wait until I have more time. Although, there is another issue that I recently found (https://github.com/spyder-ide/spyder/issues/15900) that I could help with if it's necessary as it's a critical bug.
Issue Report Checklist
conda update spyder
(orpip
, if not using Anaconda)jupyter qtconsole
(if console-related)spyder --reset
Problem Description
The LSP specifies that textDocumentSymbol request can respond with
DocumentSymbol
orSymbolInformation
. Currently, spyder only supportsSymbolInformation
so I would like to suggest adding support toDocumentSymbol
since it specifies children's objects, therefore reducing the Spyder's computational weight to search for possible parents.Refer to Language Server Protocol for more details.
A workaround can be made by patching
spyder.editor.widgets.codeeditor.CodeEditor.process_symbols
:What steps reproduce the problem?
DocumentSymbol
instead ofSymbolInformation
What is the expected output? What do you see instead?
It's expected a populated Tree in Outline Panel, but nothing is displayed.
Paste Traceback/Error Below (if applicable)
Versions
Dependencies