Sodium does not apply config overrides if config file is not present
kvverti opened this issue ยท 1 comments
Expected Behavior
Sodium should apply config overrides from mods' fabric.mod.json
after creating the default blank config on the first ever load.
Actual Behavior
When loading for the first time, Sodium will not apply config overrides from mods' fabric.mod.json
. This can result in crashes if a mod disables certain Sodium mixins due to mixin conflicts.
I believe this code needs a config.applyOverrides()
.
Reproduction
This crash can be reproduced using the following "minimal" real world mod setup:
- Fabric API 0.40.1
- Sodium 0.3.2
- Cloth Config 5.0.38
- Colormatic 2.2.10 (this mod disables some mixins due to a redirect conflict)
which results in the following crash:
initial_crash.log
It is likely that any mod that disables Sodium mixins in order to prevent mixin conflicts is affected by this issue.
A workaround is to simply load the game again, so that Sodium reads a config file.
This makes sense to me and seems pretty obvious in retrospect. I think our other mods had similar issues at one point as well, but it was not fixed in Sodium. I can't remember exactly.
I'll keep track of this to be fixed when we move all our mods towards one shared library for mixin configuration. Right now it's a mess between everything.