godotengine / godot-proposals

Godot Improvement Proposals (GIPs)
MIT License
1.17k stars 98 forks source link

[UI/UX] Improve the debug log #10702

Open btarg opened 2 months ago

btarg commented 2 months ago

Describe the project you are working on

A turn-based RPG

Describe the problem or limitation you are having in your project

The current debug log is difficult to read and parse, especially when compared to Unity's. It also does not have any debug functionality besides simply outputting text.

Describe the feature / enhancement and how it helps to overcome the problem or limitation

Readability

Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams

n/a

If this enhancement will not be used often, can it be worked around with a few lines of script?

No

Is there a reason why this should be core and not an add-on in the asset library?

It is a core part of the editor

AThousandShips commented 2 months ago

Within a stack trace, references to files and line numbers are printed. These should also become like hyperlinks that the user can click to find exactly where in their editor these errors come from. This cannot currently be done in VS Code with the Godot extension as res:// file paths are not supported in VS Code - but the functionality is part of that editor.

Already tracked in:

passivestar commented 2 months ago

Already tracked in:

Also in https://github.com/godotengine/godot-proposals/issues/10000

btarg commented 2 months ago

Already tracked in:

Also in #10000 Thank you for showing me both of these! Are there any issues pertaining to the other ideas I mentioned already? Also would implementing #10000 using rich text tags make the output logs look weird outside of the Godot Editor? (e.g. vscode or saved to a text file)

Calinou commented 2 months ago

When a regular string, error or stack trace are printed, the user should be able to double-click a non-hyperlinked part of the line to open the associated print function in their editor.

This is already being tracked in https://github.com/godotengine/godot-proposals/issues/9367. I don't recommend using double-clicking for that though, as double-clicking is already used to select the word under the cursor.