Craftoria

Craftoria

816k Downloads

[Bug Report]: Trying to view an enchant book in ars nouveau causes game to crash to desktop

Nexyl957 opened this issue ยท 10 comments

commented

Modpack Version

1.23.0

Describe your issue.

If you go through the ars nouveau book you can look at the different ways to get enchants using the enchanting apparatus. Hovering your mouse over one of these books (at least an Unbreaking one) causes the game to immediately crash to desktop. I did it twice in a row.

Crash Report

https://gist.github.com/Nexyl957/1ae373c1c65d22284a79e6ea025379f6

Latest Log

https://gist.github.com/Nexyl957/53e660a71342b5d7d7219a5b255fb272

Have you modified the modpack?

No

User Modifications

No response

Did the issue happen in singleplayer or on a server?

Server

Discord Username

.sylent

commented

This is a bug in xycraft and has already been reported to their dev Soaryn/XyCraftTracker#78
already addressed in development for the craftoria core mod since the xycraft dev seems to have significantly limited time available to fix their mod.

commented

This is a different problem. The bug reported that was fixed internally is specifically in regards to when the item is not supposed to have any tooltips. THIS bug with AN, is caused by the list not being properly populated when gathering the list.

commented

@Soaryn the crash itself is caused by your mod failing to check whether the list has entries before attempting to remove one.

I concede that AN may not be intending to render an empty tooltip list, but any mod can clear the mutable list intentionally or attempt to gather custom tooltips by passing an empty list to the event which would cause your mod to crash. your mod makes assumptions, which are not guaranteed, and thus crashes the game.

commented

I have a check internally in 1.21.4+, but any mod fully clearing that list is also clearing the name. If they want full empty, the event should be canceled. It shouldnt crash, but I am being sent incorrect data to begin with here.

commented

this modpack is on 1.21.1.

edit: also, again, the list is mutable. ANY mod can clear the list at any time in the event.

commented

I'm aware of it being 1.21.1, because of gradle shenanigans I fixed up in 21.3+ opening up 21.1 is a bit of a pain. The issue you referenced was in January which was middle of 21.4 porting. Since then as you have pointed out I have limited time, but there are solutions that are handleable.

Yes, the list is mutable, I make use of that, but clearing the list is a bit of a problem. If the goal of someone is to have an empty tooltip, they need to cancel the event or add the component to the item to hide the tooltip (which is what my original issue was from), and not clear the list. Clearing just ensures that what ever WAS there is now not (which includes the name in vanilla), but doesn't prevent others from adding back to it and effectively just becomes obnoxious on the player side as now load order dictates what will print.

To be clear, yes I am aware I need to have a different handling on it to be slightly more defensive in code (as I do in 21.4+), but what is being passed in right now from AN, with or without this check, is incorrect. I might raise an issue though on Neo forge to get some more clear guideline documentation on that event as it seems to also run even when tooltips are hidden (though that one may actually be an oversight now with data components).

commented

something to be aware of is that neoforge events can be posted to the bus outside of the default neoforge patches, as well. its never safe to assume what you will be provided other than it should adhere to the contract (and javadocs if they exist). This is the case with AN. they are not posting the event in the vanilla location but appear to be posting it to collect added tooltips (not vanilla ones nor modified ones). While i would agree the code is not how i would do it (and would lead to some undesired results), the code itself is not invalid. code style and choice can be addressed with the mod but its not an AN bug, its an xycraft bug caused by unexpected valid usages of an event.

commented

Is this still not fixed? I understand that is a bit of a rhetorical question. But it is a pretty debilitating issue for people playing the pack. Every time we try to look up something from the guide book in one of the major mods of the pack, the game crashes.

commented

Is this still not fixed? I understand that is a bit of a rhetorical question. But it is a pretty debilitating issue for people playing the pack. Every time we try to look up something from the guide book in one of the major mods of the pack, the game crashes.

I understand your frustration but your comment adds nothing to the bug report and would be better suited to a chat channel if you just need an outlet to share your frustration.

It was fixed in dev for the helper mod the pack uses but real life time is limited so it has not made it into a full release yet. everyone on the pack dev team is an unpaid volunteer and real life responsibilities come first.

Xycraft dev has released a new mod version for their mods which will need to be tested before integrating into the pack and determining if the issue is resolved.

Tldr; yes, it hasn't even been 3 weeks and efforts have already been made. Fixes are under development. Patience is an important life skill.

commented

I assumed letting the dev know that the bug was debilitating was pertinent. Understanding relevance is an important life skill too.