-
-
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 use_sub_threads = true causes Player to crash semi-randomly #84012
Comments
#85039 seems to have fixed this. |
Upon further testing, it is still happening. The crashing is still unpredictable, but where it happens is consistent. I've tested it on Linux (Steam Deck) and Windows. To break down the issue further, I split my largest scene into a series of smaller scenes, in order to pinpoint the problem. I will provide a more thorough breakdown of where it happens, along with an updated test build, ASAP. |
The updated project file is here, same as in the above description. The instructions for replicating this bug remain the same as in the above description. In order to get more specific info from this test, I have set up a series of seven levels, loaded sequentially, via the load_threaded_request command. The first five scenes mostly contain level geometry, textures and collisions. The last two scenes, StationObjects (station_interior_objects.tscn) and StationPeople (station_interior_people.tscn) , are the more complex scenes. StationPeople has seven separate sub-scenes. Each of those subscenes has the same subscene within that. These sub-scenes include mesh data, skeletons, bespoke animations, a variety of different texture files. As far as I can tell, they're not heavy, but they are intricate. After going through the new game prompt, I go through the loading sequence eleven times. Test 1 - Crash at StationPeople (station_interior_people.tscn) I do this again another 10 times. Test 1 - Crash at StationPeople (station_interior_people.tscn) The current workaround: After identifying that StationObjects and StationPeople are the problematic scenes, I've opted to load them using the more straightforward load() command. Load() works 100% of the time on all scenes. |
I have this exact same issue in my project. If I disable |
Update: I have found that if remove uses of Switching to |
I'm still having this issue with version 4.3.stable. |
Godot version
4.2 Beta 3, 4.2rc2
System information
Godot v4.2.beta3 - Windows 10.0.22621 - Vulkan (Forward+) - dedicated NVIDIA GeForce RTX 2060 (NVIDIA; 31.0.15.3758) - Intel(R) Core(TM) i7-8700K CPU @ 3.70GHz (12 Threads)
Issue description
Note: This issue may be related to #78734. While that issue had resolved for me personally, (first in #78974 and later in #85039), I believe this new issue is being caused by something else. The behavior around this crash is different. It may center around how the ResourceLoader.load_threaded_request uses sub-threads to unpack more complex scenes or scenes that contain other scenes. If you need me to provide more information or more detailed crash dumps, let me know.
When I try to load a specific level in my game, the Player crashes to desktop. This has happened across three different computers, three different versions (4.1.2, 4.2b3, 4.2rc2) and two environments (Windows, Linux).
When I try to attempt to start the game again, there is a chance it may work. The functionality of the level loading successfully is unpredictable but I've noticed several factors:
In the below scene you will see two unsuccessful attempts to load the level, followed by a successful one. The successful load happened when I switched the visibility of two identical nodes.
note: more in-depth tests are below in the comments, but it points to the same problem
Windows error:
Faulting application name: Godot_v4.2-beta3_win64.exe, version: 4.2.0.0, time stamp: 0x00000000
Faulting module name: Godot_v4.2-beta3_win64.exe, version: 4.2.0.0, time stamp: 0x00000000
Exception code: 0xc0000005
Fault offset: 0x00000000002ee662
Faulting process id: 0x0x282C
Faulting application start time: 0x0x1DA08139EF66271
Faulting application path: C:\Users\gregh\AppData\Roaming\Godot\app_userdata\Godot Version Manager\versions\Godot_v4.2-beta3_win64.exe
Faulting module path: C:\Users\gregh\AppData\Roaming\Godot\app_userdata\Godot Version Manager\versions\Godot_v4.2-beta3_win64.exe
Report Id: 90acc9f6-6ec0-4952-889d-b89f59e423a5
Faulting package full name:
Faulting package-relative application ID:
Steps to reproduce
Download the scene here, also posted below.
Press F5 top run the game.
Start a new game and follow the prompts.
Notice that the scene either runs or crashes.
Quit the game manually.
Try this ten times. Try making some minor changes in the scene. Several attempts should reveal that there is no consistency to whether the level to loads or the game to crashes.
Minimal reproduction project
Download the scene here, also posted above.
The text was updated successfully, but these errors were encountered: