isXander / MixinConflictHelper

User-friendly errors for Mixin conflicts.
GNU Lesser General Public License v3.0
13 stars 1 forks source link

Doesn't really allow the game to crash #5

Open Madis0 opened 2 years ago

Madis0 commented 2 years ago

The readme says this:

This mod catches injection exceptions when two mixins conflict. It finds the culprits and displays a user-friendly GUI, explaining the problem and providing buttons to report the issue to the mod's issues page.

Once interacted with, the game crashes as usual.

However, the mod doesn't actually crash as usual. Yes, it displays the Fabric crash window, but the crash itself only partially appears in latest.log, missing the user's list of mods, system specs etc.

Related: #4

isXander commented 2 years ago

Weird. I'll have a look at this.

Madis0 commented 2 years ago

Apparently Fabric Loader itself also pushes these stacktraces to logs, so can't blame MixinConflictHelper for that.

But I got this claim from a different dev, so there is still something to fix:

MixinConflictHelper wraps the stack with its own, which leads to a portion of the stack missing cause its too long

isXander commented 2 years ago

Could the dev comment on this thread with further explanations? By wrapping it should only add to the stacktrace like so:

Caused by: dev.isxander.mixinconflicthelper.exception.MixinConflictException: mod tried to inject into code already modified by mod
  *mixinconflicthelper call stack*
Caused by: original error
  *original error call stack*
Madis0 commented 2 years ago

I've now got a gist here, looks like it was a bug with the mod itself, that HeadlessException shouldn't be there https://gist.github.com/Mattabase/8bddcfa48f5493c54f55132afac1aff9