Infinite loop crash during item extraction
LemmaEOF opened this issue ยท 3 comments
Describe the Bug
A friend encountered an error where a brass funnel attempting to perform extraction ended up in an infinite loop crash due to a StackOverflowError
on ItemHelper#extract(Storage<ItemVariant> inv, Predicate<ItemStack> test, ExtractionCountMode mode, int amount, boolean simulate)
. This crash now occurs every time the world is loaded, making it impossible to enter.
Reproduction Steps
Direct quote from the user who experienced the crash:
okay so we had a belt loop with one corner replaced by a barrel buffer, one brass funnel from belt to the barrel, another extracted anything from the barrel back onto the start of the belt.
there's a second connect to the loop with a different belt feeding in, which has a brass funnel extracting with a golden sheet filter from a depot. we doubt it was the the one connected to the depot as that was working shortly before the world crash locked
there was a moving belt under the barrel as well, but that (hopefully) shouldn't do anything
A picture of the machine that caused this crash is included in the screenshots and videos section.
Expected Result
The game doesn't crash with a StackOverflowException
Screenshots and Videos
The crashing machine has been recreated unpowered in another world, and Deployers in the setup have been removed for ease of visibility.
Crash Report or Log
https://gist.github.com/LemmaEOF/6758a2d6b2e6bbd51c4bc57de306b950
Operating System
N/A - should not affect anything
Mod Version
0.5.0d
Minecraft Version
1.18.2
Other Mods
Many (see log), but Create was the only mod used in the crashing machine setup
Additional Context
No response
Note this version of the machine itself seems to be running fine now, it may be related to pulling incomplete precision mechanisms in and out of the barrel, as plain golden sheets alone have yet to cause the crash again.
nvm the entire setup has been recreated and run and still hasn't crashed, while clearly the bug is still here, there's something weird about reproducing the issue.
The caution in rebuilding the original machine that crashed without running it, seems to have been overkill
we understand full well that the setup not crashing later makes this even harder to track down uhh...
I have probably encountered the same bug in the Cabricality modpack and found a way to reliably reproduce it:
- Place a barrel or chest
- Add a brass funnel so that it extracts items
- Set the brass funnel filter to 64
- Get a stack of (identically) named items
- Split that stack of named items across multiple slots in the storage
- The brass funnel is now a ticking block and will crash the world
Video of the crash: https://gfycat.com/energeticallaustralianfurseal
Notes:
- I haven't tested extensively, but I think the number on the funnel doesn't matter as long as it's not * and it's combining items from at least 2 slots in the attached storage.
- Regular items work as intended, I had to name mine to cause the crash. Partial mechanisms also have extra data (to store progress), so it may just be related to having any extra data on the item.