godotengine / godot-vscode-plugin

Godot development tools for VSCode
MIT License
1.47k stars 148 forks source link

Conditional breakpoints are considered "not supported by this debugger" #633

Open hsandt opened 3 months ago

hsandt commented 3 months ago

Godot version

v4.2.1.stable.official [b09f793f5]

VS Code version

1.86.2

Godot Tools VS Code extension version

2.0.0

System information

Ubuntu 22.04.4 LTS 22.04 - X11 - Vulkan (Mobile) - dedicated NVIDIA GeForce GTX 860M (nvidia; 535.161.07) - Intel(R) Core(TM) i7-4710HQ CPU @ 2.50GHz (8 Threads)

Issue description

I added a conditional breakpoint that should be false, but it still hits. Then I noticed it was marked with a warning sign, and on hover it says:

Breakpoints of this type are not supported by the debugger Condition: false

image

https://github.com/godotengine/godot-vscode-plugin/issues/267 is closed so conditional breakpoints should be supported.

My launch.json is:

{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
        {
            "name": "GDScript: Launch Project",
            "type": "godot",
            "request": "launch",
            "project": "${workspaceFolder}",
            "debug_collisions": false,
            "debug_paths": false,
            "debug_navigation": false,
            "additional_options": ""
        }
    ]
}

Am I missing some configuration?

Steps to reproduce

  1. Open Godot project folder
  2. Create launch.json as above
  3. Add conditional breakpoint to some .gd script on code that is run. Set condition to false to make it obvious it shouldn't hit.
  4. Launch Godot project via VS Code.
  5. Observe how it breaks
  6. Hover conditional breakpoint to see warning message
atirut-w commented 2 months ago

I think this might be more of a missing feature, but it could probably be added on the IDE side by manually evaluating conditions.