godot icon indicating copy to clipboard operation
godot copied to clipboard

RichTextLabel crashes application on exit

Open Dunkhan opened this issue 3 years ago • 3 comments

Godot version

4.0 Beta 3

System information

Linux (Linux Mint 20.3 Cinnamon)

Issue description

Having a rich text label in a scene causes the application to crash when it tries to exit. This happens in exported versions and in external debuggers. The editor does not log these messages when the application is run from there. I have not tested this on windows or with the stable version.

The error messages that result are:
ERROR: Attempted to free invalid ID: 0
   at: _free_internal (drivers/vulkan/rendering_device_vulkan.cpp:8838)
ERROR: Attempted to free invalid ID: 0
   at: _free_internal (drivers/vulkan/rendering_device_vulkan.cpp:8838)
ERROR: Attempted to free invalid ID: 0
   at: _free_internal (drivers/vulkan/rendering_device_vulkan.cpp:8838)
ERROR: Attempted to free invalid ID: 0
   at: _free_internal (drivers/vulkan/rendering_device_vulkan.cpp:8838)
ERROR: Attempted to free invalid ID: 0
   at: _free_internal (drivers/vulkan/rendering_device_vulkan.cpp:8838)
ERROR: Condition "!shader" is true.
   at: shader_free (servers/rendering/renderer_rd/storage_rd/material_storage.cpp:2328)
ERROR: Condition "!material" is true.
   at: material_free (servers/rendering/renderer_rd/storage_rd/material_storage.cpp:2561)

Steps to reproduce

Create a project Create a UI scene Add a RichTextLabel to the scene with some text in it Make the scene the default starting scene Export the application Start the application from the command line Exit the application Check the command line output

This might not seem like a big deal as the application is closing anyway, but there are two reasons why this is still something to be concerned about.

The application does not return an exit code of 0 meaning that other applications (e.g launcher) that check if the program crashed or ran successfully will always report that it crashed. Whatever is causing this might have other effects in more complex scenarios. I found this while trying to debug a crash bug that I am having that appears to be related.

Minimal reproduction project

literally just a control with a RichTextLabel, I can upload one anyway if needed, let me know.

Dunkhan avatar Nov 03 '22 10:11 Dunkhan

I'm getting a few unclaimed string names, but no crash with beta 4 and custom master build.

Orphan StringName: SceneMultiplayer
Orphan StringName: FileAccess
StringName: 2 unclaimed string names at exit.

It's either already fixed or not related to RTL (rendering_device_vulkan error might indicate GPU driver issue).

bruvzg avatar Nov 03 '22 14:11 bruvzg

Tried with beta 4, exact same list of errors

Dunkhan avatar Nov 04 '22 17:11 Dunkhan

I can upload one anyway if needed, let me know.

Please, do. And please always assume it is needed by default 🙃

YuriSizov avatar Mar 07 '23 13:03 YuriSizov

This is no longer occurring. There have been extensive changes to the RichTextLabel since this was reported, likely one of those fixed the issue.

Dunkhan avatar Mar 07 '23 18:03 Dunkhan