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

Godot Editor crashes whenever I try and open or create a project using the compiled master branch. #79936

Closed
Angular-Angel opened this issue Jul 26, 2023 · 17 comments

Comments

@Angular-Angel
Copy link

Angular-Angel commented Jul 26, 2023

Godot version

4.0 master commit: 8367152

System information

           `-/osyhddddhyso/-`              angle@Sager 
        .+yddddddddddddddddddy+.           ----------- 
      :yddddddddddddddddddddddddy:         OS: Xubuntu 23.04 x86_64 
    -yddddddddddddddddddddhdddddddy-       Kernel: 6.2.0-26-generic 
   odddddddddddyshdddddddh`dddd+ydddo      Uptime: 2 hours, 14 mins 
 `yddddddhshdd-   ydddddd+`ddh.:dddddy`    Packages: 5713 (dpkg), 11 (brew), 21 
 sddddddy   /d.   :dddddd-:dy`-ddddddds    Shell: bash 5.2.15 
:ddddddds    /+   .dddddd`yy`:ddddddddd:   Resolution: 1920x1080 
sdddddddd`    .    .-:/+ssdyodddddddddds   DE: Xfce 4.18 
ddddddddy                  `:ohddddddddd   WM: Xfwm4 
dddddddd.                      +dddddddd   WM Theme: Default 
sddddddy                        ydddddds   Theme: Greybird [GTK2/3] 
:dddddd+                      .oddddddd:   Icons: elementary-xfce-darker [GTK2/ 
 sdddddo                   ./ydddddddds    Terminal: xfce4-terminal 
 `yddddd.              `:ohddddddddddy`    Terminal Font: Monospace 12 
   oddddh/`      `.:+shdddddddddddddo      CPU: Intel i5-6500 (4) @ 3.600GHz 
    -ydddddhyssyhdddddddddddddddddy-       GPU: NVIDIA GeForce GTX 1050 Ti 
      :yddddddddddddddddddddddddy:         Memory: 6966MiB / 23975MiB 
        .+yddddddddddddddddddy+.
           `-/osyhddddhyso/-`                                      

Issue description

When I compile the latest version of Godot Engine, and then try to run it and open a 4.1 project, or even create a new project, it crashes silently, usually without any kind of error message. I've been having this problem for almost a week now, and it has persisted across me pulling master and recompiling several times. Only once did I manage to get any kind of error message:

Godot Engine v4.2.dev.custom_build.29c21e020 - https://godotengine.org
OpenGL API 3.3.0 NVIDIA 525.125.06 - Compatibility - Using Device: NVIDIA - NVIDIA GeForce GTX 1050 Ti
 
Project is missing: /home/angle/Documents/Programming/GodotEngine/Projects/4.0/Advanced Movement System Godot (AMSG) Template/project.godot
Editing project: /home/angle/Documents/Programming/GodotEngine/Projects/4.0/Omnicraft
Godot Engine v4.2.dev.custom_build.29c21e020 - https://godotengine.org
Vulkan API 1.3.224 - Forward+ - Using Vulkan Device #0: NVIDIA - NVIDIA GeForce GTX 1050 Ti
WARNING: Invalid pipelines cache header.
     at: _load_pipeline_cache (drivers/vulkan/rendering_device_vulkan.cpp:9071)

Steps to reproduce

Compile the latest version of Godot from the master branch on a linux machine and then run it and try to create a new project.

Minimal reproduction project

N/A

@Calinou
Copy link
Member

Calinou commented Jul 26, 2023

Can you reproduce this issue with official releases from https://godotengine.org/?

Do you have MangoHUD globally enabled? See flightlessmango/MangoHud#706.

@Angular-Angel
Copy link
Author

So apparently this only happens when I run the thing from Netbeans, not when I run the executable from file manager or from terminal. Gonna do some more thorough testing... :/

@Angular-Angel
Copy link
Author

I did not do anything to enable MangoHUD, so I don't think it's that.

@aaronfranke
Copy link
Member

aaronfranke commented Jul 27, 2023

@Angular-Angel I think I am experiencing the same crash as you. Does the problem go away if you revert to c4e5822, and come back if you fast-forward to 7c20487? The crash goes away if I revert PR #78615.

macOS is giving me this information when it crashes:

libc++abi: terminating due to uncaught exception of type std::__1::system_error: recursive_mutex lock failed: Invalid argument
Thread 0 Crashed::  Dispatch queue: com.apple.main-thread
0   libsystem_kernel.dylib        	       0x1842fc724 __pthread_kill + 8
1   libsystem_pthread.dylib       	       0x184333c28 pthread_kill + 288
2   libsystem_c.dylib             	       0x184241ae8 abort + 180
3   libc++abi.dylib               	       0x1842ecb84 abort_message + 132
4   libc++abi.dylib               	       0x1842dc3b4 demangling_terminate_handler() + 320
5   libobjc.A.dylib               	       0x183fb303c _objc_terminate() + 160
6   libc++abi.dylib               	       0x1842ebf48 std::__terminate(void (*)()) + 16
7   libc++abi.dylib               	       0x1842eed34 __cxxabiv1::failed_throw(__cxxabiv1::__cxa_exception*) + 36
8   libc++abi.dylib               	       0x1842eece0 __cxa_throw + 140
9   libc++.1.dylib                	       0x18426a8b4 std::__1::__throw_system_error(int, char const*) + 100
10  libc++.1.dylib                	       0x18425f11c std::__1::recursive_mutex::lock() + 40
11  godot.macos.editor.arm64      	       0x104ba1abc ResourceImporterTexture::update_imports() + 96
12  godot.macos.editor.arm64      	       0x104596958 EditorNode::_notification(int) + 2764
13  godot.macos.editor.arm64      	       0x1045fea98 0x102ce4000 + 26323608
14  godot.macos.editor.arm64      	       0x10721e178 Object::notification(int, bool) + 32
15  godot.macos.editor.arm64      	       0x10535d530 SceneTree::_process_group(SceneTree::ProcessGroup*, bool) + 280
16  godot.macos.editor.arm64      	       0x10535b398 SceneTree::_process(bool) + 676
17  godot.macos.editor.arm64      	       0x10535bafc SceneTree::process(double) + 240
18  godot.macos.editor.arm64      	       0x10309ae88 Main::iteration() + 952
19  godot.macos.editor.arm64      	       0x10304ca2c OS_MacOS::run() + 116
20  godot.macos.editor.arm64      	       0x103075db8 main + 304
21  dyld                          	       0x183fdbf28 start + 2236

@YuriSizov
Copy link
Contributor

@aaronfranke OP says they've had this issue for a week. This PR is freshly merged, so unlikely to be the culprit in their case.

@Angular-Angel
Copy link
Author

Well, roughly a week. I first noticed it on either the 21st or the 22nd, I don't remember which.

@Angular-Angel
Copy link
Author

Going to see if I can figure out how to compile a dev build and use gdb to get a better debug message. See if that gets me anywhere. :/

@Angular-Angel
Copy link
Author

...Well, I got something! This is with the Voxel tools module added as well:

Vulkan API 1.3.224 - Forward+ - Using Vulkan Device #0: NVIDIA - NVIDIA GeForce GTX 1050 Ti
 
WARNING: Blend file import is enabled in the project settings, but no Blender path is configured in the editor settings. Blend files will not be imported.
     at: _editor_init (modules/gltf/register_types.cpp:73)

================================================================
handle_crash: Program crashed with signal 11
Engine version: Godot Engine v4.2.dev.custom_build (884ba6af85194c0d7e381ab0e0b28e0441c20a2b)
Dumping the backtrace. Please include this when reporting the bug to the project developer.
[1] /lib/x86_64-linux-gnu/libc.so.6(+0x3c4b0) [0x7f18c303c4b0] (??:0)
[2] /lib/x86_64-linux-gnu/libc.so.6(pthread_mutex_lock+0x4) [0x7f18c3092464] (??:0)
[3] /home/angle/Documents/Programming/C++/GodotEngine/godot/bin/godot.linuxbsd.editor.x86_64(+0x2b79f5e) [0x55e80906cf5e] (??:0)
[4] /home/angle/Documents/Programming/C++/GodotEngine/godot/bin/godot.linuxbsd.editor.x86_64(+0x264ad68) [0x55e808b3dd68] (??:0)
[5] /home/angle/Documents/Programming/C++/GodotEngine/godot/bin/godot.linuxbsd.editor.x86_64(+0x5919c88) [0x55e80be0cc88] (??:0)
[6] /home/angle/Documents/Programming/C++/GodotEngine/godot/bin/godot.linuxbsd.editor.x86_64(+0x37bd457) [0x55e809cb0457] (??:0)
[7] /home/angle/Documents/Programming/C++/GodotEngine/godot/bin/godot.linuxbsd.editor.x86_64(+0x37bda80) [0x55e809cb0a80] (??:0)
[8] /home/angle/Documents/Programming/C++/GodotEngine/godot/bin/godot.linuxbsd.editor.x86_64(+0x37be242) [0x55e809cb1242] (??:0)
[9] /home/angle/Documents/Programming/C++/GodotEngine/godot/bin/godot.linuxbsd.editor.x86_64(+0xd8f5c5) [0x55e8072825c5] (??:0)
[10] /home/angle/Documents/Programming/C++/GodotEngine/godot/bin/godot.linuxbsd.editor.x86_64(+0xd1eb21) [0x55e807211b21] (??:0)
[11] /home/angle/Documents/Programming/C++/GodotEngine/godot/bin/godot.linuxbsd.editor.x86_64(+0xd0df7d) [0x55e807200f7d] (??:0)
[12] /lib/x86_64-linux-gnu/libc.so.6(+0x23a90) [0x7f18c3023a90] (??:0)
[13] /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0x89) [0x7f18c3023b49] (??:0)
[14] /home/angle/Documents/Programming/C++/GodotEngine/godot/bin/godot.linuxbsd.editor.x86_64(+0xd1cbd5) [0x55e80720fbd5] (??:0)
-- END OF BACKTRACE --
================================================================

@YuriSizov
Copy link
Contributor

@Angular-Angel Thanks for helping with the investigation! You need to compile with debug_symbols=yes, or dev_build=yes which includes it. Otherwise your build doesn't include debug symbols and the stack trace is obfuscated.

@Angular-Angel
Copy link
Author

Right! I tried that once, but I think I forgot to run the actual dev build executable, and instead just ran the old one again. I'll try that, gimme a bit...

@Angular-Angel
Copy link
Author

Hmm. Again, compiled with the voxel tools module. When I try and run it through Netbeans, it crashes silently on me trying to load my project, but when I run it via terminal, I get:

ERROR: 5 shaders of type SceneForwardClusteredShaderRD were never freed
   at: ~ShaderRD (servers/rendering/renderer_rd/shader_rd.cpp:708)
ERROR: FATAL: DEV_ASSERT failed  "_first == nullptr" is false.
   at: ~List (./core/templates/self_list.h:114)

================================================================
handle_crash: Program crashed with signal 4
Engine version: Godot Engine v4.2.dev.custom_build (884ba6af85194c0d7e381ab0e0b28e0441c20a2b)
Dumping the backtrace. Please include this when reporting the bug to the project developer.
[1] /lib/x86_64-linux-gnu/libc.so.6(+0x3c4b0) [0x7f684503c4b0] (??:0)
[2] SelfList<RendererSceneRenderImplementation::SceneShaderForwardClustered::ShaderData>::List::~List() (/home/angle/Documents/Programming/C++/GodotEngine/godot/./core/templates/self_list.h:114 (discriminator 1))
[3] RendererSceneRenderImplementation::SceneShaderForwardClustered::~SceneShaderForwardClustered() (/home/angle/Documents/Programming/C++/GodotEngine/godot/servers/rendering/renderer_rd/forward_clustered/scene_shader_forward_clustered.cpp:473)
[4] RendererSceneRenderImplementation::RenderForwardClustered::~RenderForwardClustered() (/home/angle/Documents/Programming/C++/GodotEngine/godot/servers/rendering/renderer_rd/forward_clustered/render_forward_clustered.cpp:4007)
[5] void memdelete<RendererSceneRenderRD>(RendererSceneRenderRD*) (/home/angle/Documents/Programming/C++/GodotEngine/godot/./core/os/memory.h:112)
[6] RendererCompositorRD::finalize() (/home/angle/Documents/Programming/C++/GodotEngine/godot/servers/rendering/renderer_rd/renderer_compositor_rd.cpp:150)
[7] RenderingServerDefault::_finish() (/home/angle/Documents/Programming/C++/GodotEngine/godot/servers/rendering/rendering_server_default.cpp:218)
[8] RenderingServerDefault::finish() (/home/angle/Documents/Programming/C++/GodotEngine/godot/servers/rendering/rendering_server_default.cpp:246)
[9] finalize_display() (/home/angle/Documents/Programming/C++/GodotEngine/godot/main/main.cpp:314)
[10] Main::cleanup(bool) (/home/angle/Documents/Programming/C++/GodotEngine/godot/main/main.cpp:3640)
[11] /home/angle/Documents/Programming/C++/GodotEngine/godot/bin/godot.linuxbsd.editor.dev.x86_64(main+0x1a9) [0x5559ba5940e2] (/home/angle/Documents/Programming/C++/GodotEngine/godot/platform/linuxbsd/godot_linuxbsd.cpp:78)
[12] /lib/x86_64-linux-gnu/libc.so.6(+0x23a90) [0x7f6845023a90] (??:0)
[13] /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0x89) [0x7f6845023b49] (??:0)
[14] /home/angle/Documents/Programming/C++/GodotEngine/godot/bin/godot.linuxbsd.editor.dev.x86_64(_start+0x25) [0x5559ba593e75] (??:?)
-- END OF BACKTRACE --
================================================================

After loading the project, running it, and waiting a bit. Same thing I did for the last error message. :/

@Angular-Angel
Copy link
Author

Angular-Angel commented Jul 27, 2023

There's a bunch more stuff in the log, but I don't think it's related to the crash.

@Angular-Angel
Copy link
Author

Here's the code at current, though you'll also need a version of godot compiled with the latest of vthe voxel tools module to run it: https://gitlab.com/AngularAngel/omnicraftgodot/-/tree/BlockyLibraryUpdateCrash?ref_type=heads

@Angular-Angel
Copy link
Author

Angular-Angel commented Jul 27, 2023

Okay, for that crash I think it was just due to the editor getting spammed with errors - I managed to fix those, and now the editor doesn't crash. Still no idea for why my original problem is a thing, but I think it has as much to do with Netbeans as with Godot. So, this issue can probably be closed now. :/

@Angular-Angel
Copy link
Author

Yup, gonna go ahead and close this for now.

@michielpapenhove
Copy link

I am still getting this error using Godot 4.2.1 on MacOS (Sonoma 14.2.1, M1 chip)...

@Angular-Angel
Copy link
Author

I think this was also related to trying to load my project from the editor menu, instead of running it directly? These days I run it with: ./bin/godot.linuxbsd.editor.x86_64 -e --path <My_project> when I want to run a freshly compiled version from the IDE. If I run it without that and try to load a project it crashes, which I think is a well known problem. :/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants