-
-
Notifications
You must be signed in to change notification settings - Fork 21.6k
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
ResourceLoader.load_threaded_request()
hangs for use_sub_threads = true
with no error messages
#85255
Comments
Not sure how common this issue is but I'm working around it by doing separate calls to "ResourceLoader.load_threaded_request()" for those specific instanced and preloaded scenes before loading the larger scene. |
Could you test the build linked here? |
Yeah, still stuck at 0% with no error messages. |
Confirmed on Linux with latest When closing the MRP, it deadlocks. GDB gives this stacktrace:
I confirm the issue is reproducible in 4.2-rc1, 4.1-stable and 4.0-stable, so it's not a recent regression. |
ResourceLoader.load_threaded_request()
hangs for use_sub_threads = true
with no error messages
I think I have the same issue with a test project for another issue #58131: I'm on Windows 11, Godot v4.3.dev.custom_build [4f55118f4] The problem seems to be caused by a thread conflict between the resource loader and the toast because the project has some invalid .import for the pngs. If a was able to figure out that the Editor tries to add a message for the invalid loader from a thread and another thread is trying to add the toast but is not in the main thread so it raisesanother error After that the editor is completly frozen: Adding a return in EditorToaster::popup_str fixes the problem. |
Yes, I think I found the problem, but I'm not sure how to fix it. I'm not sure if a tweak in the EditorToaster is the right move and removing the MessageQueue from the ResourceLoader is probably a really bad idea. Just adding these lines at the beginning of
|
As I wrote in #92426 (comment), @Hilderin's issue seems to be different from the OP's. #92426 will fix that later report (EditorToaster deadlock), but not the OP's problem. |
Godot version
v4.2.rc1.official [ad72de5]
System information
Godot v4.2.rc1 - Windows 10.0.22621 - Vulkan (Forward+) - dedicated NVIDIA GeForce RTX 3080 (NVIDIA; 31.0.15.3758) - 11th Gen Intel(R) Core(TM) i5-11400 @ 2.60GHz (12 Threads)
Issue description
ResourceLoader.load_threaded_request() hangs indefinitely for use_sub_threads = true with no error messages.
It happens when you have an instance of a resource in a scene and are trying to preload the resource in the script of the scene.
I think it could be deadlock and the threads are stuck busy waiting, but I'm just speculating as there is no error message and I haven't looked into the source code.
Happens in v4.1.2.stable.official [399c9dc] and v4.2.rc1.official [ad72de5]
might be similar to #71726
Steps to reproduce
Minimal reproduction project
ResourceLoaderTest.zip
The text was updated successfully, but these errors were encountered: