Skip to content

Race Condition in the Presence of Bigger Stacks, ModernFix, and probably any 6 random libraries or mods #632

@Caritas-Dei

Description

@Caritas-Dei

Bug Description

For Minecraft 1.20.1, Forge 47.4.16, Bigger Stacks 2026.02.04 and ModernFix 5.26.2 in the presence of 6 (but seemingly not 5) other random libraries or mods causes a java.util.ConcurrentModificationException with the following stacktrace:

[22:17:02] [Thread-0] [STDERR/INFO]:
[java.lang.ThreadGroup:uncaughtException:-1]: java.util.ConcurrentModificationException
[22:17:02] [Thread-0] [STDERR/INFO]:
[java.lang.ThreadGroup:uncaughtException:-1]: at java.base/java.util.HashMap$HashIterator.nextNode(Unknown Source)
[22:17:02] [Thread-0] [STDERR/INFO]:
[java.lang.ThreadGroup:uncaughtException:-1]: at java.base/java.util.HashMap$ValueIterator.next(Unknown Source)
[22:17:02] [Thread-0] [STDERR/INFO]:
[java.lang.ThreadGroup:uncaughtException:-1]: at MC-BOOTSTRAP/cpw.mods.modlauncher@10.0.9/cpw.mods.modlauncher.LaunchPluginHandler.computeLaunchPluginTransformerSet(LaunchPluginHandler.java:68)
[22:17:02] [Thread-0] [STDERR/INFO]:
[java.lang.ThreadGroup:uncaughtException:-1]: at MC-BOOTSTRAP/cpw.mods.modlauncher@10.0.9/cpw.mods.modlauncher.ClassTransformer.transform(ClassTransformer.java:64)
[22:17:02] [Thread-0] [STDERR/INFO]:
[java.lang.ThreadGroup:uncaughtException:-1]: at MC-BOOTSTRAP/cpw.mods.modlauncher@10.0.9/cpw.mods.modlauncher.TransformingClassLoader.maybeTransformClassBytes(TransformingClassLoader.java:50)
[22:17:02] [Thread-0] [STDERR/INFO]:
[java.lang.ThreadGroup:uncaughtException:-1]: at cpw.mods.securejarhandler/cpw.mods.cl.ModuleClassLoader.readerToClass(ModuleClassLoader.java:113)
[22:17:02] [Thread-0] [STDERR/INFO]:
[java.lang.ThreadGroup:uncaughtException:-1]: at cpw.mods.securejarhandler/cpw.mods.cl.ModuleClassLoader.lambda$findClass$15(ModuleClassLoader.java:219)
[22:17:02] [Thread-0] [STDERR/INFO]:
[java.lang.ThreadGroup:uncaughtException:-1]: at cpw.mods.securejarhandler/cpw.mods.cl.ModuleClassLoader.loadFromModule(ModuleClassLoader.java:229)
[22:17:02] [Thread-0] [STDERR/INFO]:
[java.lang.ThreadGroup:uncaughtException:-1]: at cpw.mods.securejarhandler/cpw.mods.cl.ModuleClassLoader.findClass(ModuleClassLoader.java:219)
[22:17:02] [Thread-0] [STDERR/INFO]:
[java.lang.ThreadGroup:uncaughtException:-1]: at cpw.mods.securejarhandler/cpw.mods.cl.ModuleClassLoader.loadClass(ModuleClassLoader.java:135)
[22:17:02] [Thread-0] [STDERR/INFO]:
[java.lang.ThreadGroup:uncaughtException:-1]: at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
[22:17:02] [Thread-0] [STDERR/INFO]:
[java.lang.ThreadGroup:uncaughtException:-1]: at TRANSFORMER/modernfix@5.26.2+mc1.20.1/org.embeddedt.modernfix.forge.config.NightConfigWatchThrottler$1.values(NightConfigWatchThrottler.java:37)
[22:17:02] [Thread-0] [STDERR/INFO]:
[java.lang.ThreadGroup:uncaughtException:-1]: at MC-BOOTSTRAP/com.electronwill.nightconfig.core@3.6.4/com.electronwill.nightconfig.core.file.FileWatcher$WatcherThread.run(FileWatcher.java:162)

Reproduction Steps

My CPU is a Ryzen 9 3950X, 16 cores, 32 threads; GPU is Radeon RX 5700 XT with driver version 26.1.1 .

  1. Install Minecraft 1.20.1 with authenticated account, Forge 47.4.6, latest Bigger Stacks and ModernFix, followed by any 6 mods whether libraries or not. The additional mods I tested with, however (ignoring a few random enables), are: TelluriumForge, TenshiLib, Uranus, Voltaic, YetAnotherConfigLib, and Zeta.
  2. Run the game
  3. Check for the above type of stacktrace occurring as a ConcurrentModificationException
  4. Try with 5 mods and repeat steps 2-3.
  5. Try with 5 mods but no ModernFix enabled and repeat steps 2-3.
  6. Try with at least one new mod replacing one of the 6 mods and repeat steps 2-3.
  7. Try with at least one new mod replacing one of the 6 mods and repeat steps 2-3, but without ModernFix.

Note: setting mixin.feature.cause_lag_by_disabling_threads=true will not change these results.

Log File

launcher_log.txt is latest.log but with lines added before and after by Modrinth Launcher

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions