Skip to content
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

Add Lines Before "extends Node" Result in Outline Not Working #658

Open
hayahane opened this issue May 18, 2024 · 7 comments
Open

Add Lines Before "extends Node" Result in Outline Not Working #658

hayahane opened this issue May 18, 2024 · 7 comments
Labels
bug language server Issue is not originating from this extension, but from the LSP instead needs testing

Comments

@hayahane
Copy link

Godot version

4.3dev6

VS Code version

1.89.1

Godot Tools VS Code extension version

2.0.0

System information

Windows 11

Issue description

The outline does not work properly when "extends Node" not in the first Line.
I've found several situation:

  • class_name in the first line, and extends in the second:
    [work properly]
    image
    image
    [not working]
    image
    image

  • use icon notation:
    image
    image

  • write comments when not using class_name:
    [comments without class_name]
    image
    image
    [comments with class_name]
    image
    image

Steps to reproduce

Simply write a piece of code.
The situations I found are above.

@limbonaut
Copy link

I can confirm this issue with some of the LimboAI scripts, such as:
https://github.com/limbonaut/limboai/blob/master/demo/demo/agents/scripts/agent_base.gd

@DaelonSuzuka
Copy link
Collaborator

I don't think the extension has anything to do with this. I believe that the contents of the outline panel are directly provided by the LSP.

@DaelonSuzuka
Copy link
Collaborator

Yeah, this is a bug in the Language Server, and the issue needs to be raised in the https://github.com/godotengine/godot repo.

@HolonProduction
Copy link
Member

Yeah, this is a bug in the Language Server, and the issue needs to be raised in the https://github.com/godotengine/godot repo.

Did you look into what the Server is actually doing wrong? Looking at the traces from godotengine/godot#98164 the responses seem correct at a first glance.

@DaelonSuzuka
Copy link
Collaborator

@HolonProduction I will have to look into this further. This extension doesn't control the outline, it forwards those messages directly to VSCode, so if only works sometimes then (in theory) there is a bug in either VSCode or the Language Server.

@HolonProduction
Copy link
Member

@DaelonSuzuka it is in fact an (not very obvious) issue with the LSP, see godotengine/godot#99295. I guess it would be fine to close this issue again.

@DaelonSuzuka
Copy link
Collaborator

That makes a lot of sense, thanks for investigating!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug language server Issue is not originating from this extension, but from the LSP instead needs testing
Projects
None yet
Development

No branches or pull requests

4 participants