[Crash]: Occasional crash when hitting the + button to move ingredients to crafting table
freevortex opened this issue ยท 5 comments
Steps to Reproduce the Crash
Sometimes, but not always, when I click the + button to move items in a recipe from my inventory to the crafting table, my game crashes with some sort of ticking entity error. It has happened with a variety of recipes, including both vanilla recipes and modded recipes.
Mod Pack URL (Optional)
No response
Mod Pack Version (Optional)
No response
Extra Notes (Optional)
No response
Crash Report
https://gist.github.com/freevortex/013c087c112e3bf56078c0deb3982315
I'm pretty sure I've found the root cause for this, JEI doesnt schedule the setItemStack stuff onto the server-thread and instead does it on the networking thread, when a packet arrives, see this stacktrace:
https://gist.github.com/someaddons/313ee21b1c0e9eb6f7cd9dc00db123c7
Which can cause a concurrent error, when something else happens to access/use the inventory aswell
Probably after reading/deserializing data, it should schedule to the server thread
Thanks for the report!
From the crash log, it looks like something in the Minecraft Advancements code is crashing when you craft something new.
Unfortunately I am not able to see what you were crafting, but I think that mod may be triggering an Advancement from the wrong thread, and Minecraft is not able to handle it well.
From what I can well, it does not look like JEI is the direct cause of this crash, since the crash appears to happen after the items are placed into the crafting grid.
Thank you for finding this @someaddons , that's not good at all.
I have submitted a fix for this (f758d0d) but the build system is not working right now, so the updated release is a bit delayed.
Please try this out when there's a new build of JEI for 1.19.2 available, it should hopefully fix this problem.