Incorrect blame for PreLaunch entrypoints
In this case it looks like better-clouds is causing a crash, when actually morenemoswoodcuttervariants is at fault by providing an invalid name/path in it's mixins.json.
Since most users only read the first error (if at all), they would blame the wrong mod for the crash. In cases like these, where an error occurs during Mixin loading (not transformation), the error message could be improved by inspecting the exception cause chain.
Mods used in example:
- https://modrinth.com/mod/more-nemos-woodcutter-variants/version/Iwdd4qgg
- https://modrinth.com/mod/better-clouds/version/1.7.4+1.21-fabric-r
This happens because Mixin initializes when it is asked to transform the first class.
We may be able to trigger this explicitly (by calling select directly), before running preLaunch, but I'm not sure this is safe to do.
The RuntimeException occured while invoking the entrypoint of better-clouds. So wyh don't you directly think about the 'deepest' exception?
Is this difficult to fix?
The issue is more general. It also happens when mixin transformation failed.
Any chance of this being fixed?
I don't think we can fix 100% of this since a failed transform will always be tied to whatever caused the class to be loaded, but the configuration phase can (and imo shoud) be separated as in PR 1064.