Modonomicon

Modonomicon

1M Downloads

Including Modonomicon causes duplicate modules to be read by java

YoItSoul opened this issue ยท 2 comments

commented

Describe your problem

repositories {

    maven {
        // location of the maven that hosts JEI files since January 2023
        name = "Jared's maven"
        url = "https://maven.blamejared.com/"
    }
    maven {
        // location of a maven mirror for JEI files, as a fallback
        name = "ModMaven"
        url = "https://modmaven.dev"
    }

    maven {
        url "https://dl.cloudsmith.io/public/klikli-dev/mods/maven/"
        content {
            includeGroup "com.klikli_dev"
        }
    }

}


dependencies {

    minecraft "net.minecraftforge:forge:${minecraft_version}-${forge_version}"

    implementation('net.sf.jopt-simple:jopt-simple:5.0.4') { version { strictly '5.0.4' } }

    compileOnly "mezz.jei:jei-${mc_version}-common-api:${jei_version}"
    compileOnly "mezz.jei:jei-${mc_version}-forge-api:${jei_version}"
    runtimeOnly "mezz.jei:jei-${mc_version}-forge:${jei_version}"

    implementation "com.klikli_dev:modonomicon-${minecraft_version}-forge:${modonomicon_version}"

}

Causes:

Exception in thread "main" java.lang.reflect.InvocationTargetException
    at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:118)
    at java.base/java.lang.reflect.Method.invoke(Method.java:580)
    at net.minecraftforge.bootstrap.Bootstrap.bootstrapMain(Bootstrap.java:133)
    at net.minecraftforge.bootstrap.Bootstrap.start(Bootstrap.java:53)
    at net.minecraftforge.bootstrap.ForgeBootstrap.main(ForgeBootstrap.java:19)
Caused by: java.lang.module.ResolutionException: Module minecraft reads more than one module named org.commonmark.ext.gfm.strikethrough
    at java.base/java.lang.module.Resolver.resolveFail(Resolver.java:900)
    at java.base/java.lang.module.Resolver.checkExportSuppliers(Resolver.java:721)
    at java.base/java.lang.module.Resolver.finish(Resolver.java:380)
    at java.base/java.lang.module.Configuration.<init>(Configuration.java:139)
    at java.base/java.lang.module.Configuration.resolveAndBind(Configuration.java:493)
    at SECURE-BOOTSTRAP/[email protected]/cpw.mods.modlauncher.ModuleLayerHandler.build(ModuleLayerHandler.java:76)
    at SECURE-BOOTSTRAP/[email protected]/cpw.mods.modlauncher.TransformationServicesHandler.buildTransformingClassLoader(TransformationServicesHandler.java:53)
    at SECURE-BOOTSTRAP/[email protected]/cpw.mods.modlauncher.Launcher.run(Launcher.java:112)
    at SECURE-BOOTSTRAP/[email protected]/cpw.mods.modlauncher.Launcher.main(Launcher.java:75)
    at SECURE-BOOTSTRAP/[email protected]/cpw.mods.modlauncher.BootstrapEntry.main(BootstrapEntry.java:17)
    at [email protected]/net.minecraftforge.bootstrap.Bootstrap.moduleMain(Bootstrap.java:188)
    at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
**Removing the mod inclusion solves this issue. JEI isn't listed as a dependency but your mod wont load without that either.**

System (please complete the following information):

  • 1.21- Forge
  • Just JEI and Modonomicon in a developer environment.
  • Modonomicon and JEI
commented
minecraft_version=1.21
mc_version=1.21
modonomicon_version=1.95.2
jei_version=19.3.1.24
commented

Fixed in 803df6a