Race condition in config loading
malte0811 opened this issue ยท 1 comments
This code can cause other mods' common configs to be dropped from configSets
due to Forge's parallel mod loading:
- Configs added during the
for
loop may be skipped/missed (the iteration is not synchronized). So they aren't added tosetBackup
, lost in the firstclear
and never re-added. - Configs added while loading the single config are lost in the second
clear
call.
I suspect that this is what causes BluSunrize/ImmersiveEngineering#5515. The code is only present on 1.18, not on 1.19, so I don't know what the third user in that issue is running into.
See also the discussion in the Forgecraft bug channel, I pinged you there at the end of the discussion (so far).