Iceberg [Forge]

Iceberg [Forge]

48M Downloads

Crash with "java.lang.ArrayIndexOutOfBoundsException: Index -1 out of bounds for length 129" when hovering over certain items and displaying its tooltip

Timolino456 opened this issue ยท 4 comments

commented

Describe the bug
I've had this issue a while now and it's a bit weird. I'm not even sure if it's caused by Iceberg or something different, but in the error Iceberg is mentioned.
Some time ago the game started crashing when opening the mod menu or sometimes the inventory, but it doesn't always happen. The errors that are not shown in the crash part of the log but before often mention multiple different mods and their GUIs.
First I disabled ToolTip Fix and the equivalent setting in Debugify because with those enabled, opening the inventories of guards from Guard Villagers made the game crash. But afterwards, simply displaying any tooltip causes a crash consistently. In the crash that I now got, the error specifically mentions Iceberg, even with the word "tooltip" in the stacktrace, which is why I'm now here.

To Reproduce
Steps to reproduce the behavior:
Other than "hover your cursor above certain items" and what I described above, I'm honestly not sure, also because I have a lot of mods.

Expected behavior
It shouldn't crash.

Environment (please complete the following information):

  • Mod name: Mods that depend on Iceberg: Advancement Plaques and Legendary Tooltips. I tried removing the latter because it literally does something to tooltips, but hovering above one of the items that always caused a crash with it removed still crashed. For other mods, see logs.
  • Mod version: 1.0.46
  • Modloader: Fabric
  • Modloader version: Fabric Loader 0.14.11 and Fabric API 0.68.0
  • Minecraft version: 1.19.2

Log files
latest.log: https://mclo.gs/bxOfdMe
crash log: https://mclo.gs/mVdwJON

Additional context
Can't think of anything.

If this indeed has to be fixed by you, it would be nice if you could make a 1.19.2 version of it, since most mods aren't updated to 1.19.3 yet. :D
If this isn't caused by Iceberg but something else, it would be nice if you could share any ideas you have of what it might be.

commented

This is interesting, I've never seen this particular crash before. Looking at the stack trace, I can see that it is crashing when attempting to calculate the tooltip width of a tooltip it is rendering. However the crash is occurring in "fastutil", which appears to be part of Prism launcher.
I will be able to fix this issue in Iceberg, however I am wary of making the change before recreating the crash myself since the crash is happening in fastutil so the game could potentially crash anywhere else this library is being used.
I will do some testing to try to recreate this.

commented

@Scrumplex Thank you for the info, I've looked into fastutil and can see that it is a well known collections library, so I doubt it is causing the crash.
@Timolino456 Unfortunately I've found that you have too many mods to even attempt to recreate this issue on my end. I will add a fix to the next version of Iceberg, but I won't be able to test the same setup that you have to ensure it works.

commented

After some time I was able to make out that this issue is in fact caused by Roughly Enough Items. I switched to EMI some days ago and this has not happened since, after trying with REI again it crashed once again.
Still, thank you for your effort!