
Issues reported with block extenders - AgSkies2 1.1.8
pjfranke opened this issue ยท 8 comments
Two separate users are reporting issues that seem to be related to the block extenders, and ticking entity/server tick loop.
Hey @pjfranke, I've just released the version with the fix to CurseForge. Sorry it took so long, updates should be more frequent from now on.
Seems to be an issue where Block Extenders and Relocators create a loop and will endlessly check if they can output. Block Extenders have code to prevent these loops, but apparently this didn't work in your world. I will try to see if I can improve this code in the next release.
You can try to enable the removal of erroring tile entities in the forge.cfg configuration file to get back into your world. When you have entered the world a Relocator or Block Extender will be removed from the world. Could you describe (or post a screenshot) of the erroring setup if you know where it is? This would help a lot in finding the issue! Don't forget to turn off the erroring tile entity removal after entering the world to make sure you don't randomly lose blocks in your world.
Thanks for reporting the issue here!
I had a chest, advanced filtered block extender (intended input) and two more basic block extenders as anna buffer for auto packagers. The relocators were coming from an auto sieve, but I had not yet figured out how to block output to unintended targets. The relocators were connecting to the chest and all block extenders instead of just the configured advanced filtered block extender. Immediate crash. I reloaded a backup and used forge microblock covers to limit output to just the AFBE and no longer encountered problems.
Okay, got the problem, but not yet sure how to best fix it, maybe @blay09 has an idea:
Item goes in Relocator and it tries to output into a Block Extender or Buffer line, which loops back into the Relocator. Item will again try to be outputted by the Relocators, but loops back again via the BE/B line. Infinite checking.
Will probably also happen with other item transport solutions. Problem should therefore be fixed at the Block Extender & Buffer.
Tried to keep a list of all ItemStacks that were tried to move and check if the same ItemStack instance would come up again in the same tick and not allow it, but that didn't work as lots of block use ItemStack::copy a lot.
Just checking a StackOverflowExceptions WILL fix it, but is the very worst solution possible, we just CANNOT use that.
Okay, found a kinda working 'fix'.
Just before we try to output in BEs/Bs we set a bool 'isOutputting' and when we get another request to output while isOutputting is true we stop and return false. After trying to output the bool is set back to false.
Awesome, thanks @Dynious . Please update when you have a new jar available on Curseforge with the change implemented.