haraldk / TwelveMonkeys

TwelveMonkeys ImageIO: Additional plug-ins and extensions for Java's ImageIO
https://haraldk.github.io/TwelveMonkeys/
BSD 3-Clause "New" or "Revised" License
1.91k stars 315 forks source link

(External) Dependency Issue in Code #1056

Open FreshImmuc opened 2 hours ago

FreshImmuc commented 2 hours ago

Describe the bug: ImageIO does NOT mark snakeyaml as an external dependency, resulting in other mods (on my minecraft server) in being unable to load, because their version of snakeyaml is different. This is the error message i get inside the server:

java.lang.module.ResolutionException: Module com.twelvemonkeys.imageio.metadata reads more than one module named org.yaml.snakeyaml
        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 MC-BOOTSTRAP/cpw.mods.modlauncher@11.0.2/cpw.mods.modlauncher.ModuleLayerHandler.buildLayer(ModuleLayerHandler.java:75)
        at MC-BOOTSTRAP/cpw.mods.modlauncher@11.0.2/cpw.mods.modlauncher.ModuleLayerHandler.buildLayer(ModuleLayerHandler.java:87)
        at MC-BOOTSTRAP/cpw.mods.modlauncher@11.0.2/cpw.mods.modlauncher.Launcher.run(Launcher.java:90)
        at MC-BOOTSTRAP/cpw.mods.modlauncher@11.0.2/cpw.mods.modlauncher.Launcher.main(Launcher.java:74)
        at MC-BOOTSTRAP/cpw.mods.modlauncher@11.0.2/cpw.mods.modlauncher.BootstrapLaunchConsumer.accept(BootstrapLaunchConsumer.java:26)
        at MC-BOOTSTRAP/cpw.mods.modlauncher@11.0.2/cpw.mods.modlauncher.BootstrapLaunchConsumer.accept(BootstrapLaunchConsumer.java:23)
        at MC-BOOTSTRAP/arclight.boot@1.21-1.0.0-SNAPSHOT/io.izzel.arclight.boot.neoforge.application.ApplicationBootstrap.accept(ApplicationBootstrap.java:47)
        at MC-BOOTSTRAP/arclight.boot@1.21-1.0.0-SNAPSHOT/io.izzel.arclight.boot.neoforge.application.ApplicationBootstrap.accept(ApplicationBootstrap.java:14)
        at cpw.mods.bootstraplauncher@2.0.2/cpw.mods.bootstraplauncher.BootstrapLauncher.run(BootstrapLauncher.java:210)
        at cpw.mods.bootstraplauncher@2.0.2/cpw.mods.bootstraplauncher.BootstrapLauncher.main(BootstrapLauncher.java:69)
        at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
        at java.base/java.lang.reflect.Method.invoke(Method.java:580)
        at io.izzel.arclight.boot.neoforge.application.Main_Neoforge.main(Main_Neoforge.java:23)
        at io.izzel.arclight.server.Launcher.main(Launcher.java:39)
Fail to launch

Version information I don't really know

  1. The exact output of java --version (or java -version for older Java releases).

    java version "21.0.5" 2024-10-15 LTS
    Java(TM) SE Runtime Environment (build 21.0.5+9-LTS-239)
    Java HotSpot(TM) 64-Bit Server VM (build 21.0.5+9-LTS-239, mixed mode, sharing)
  2. Extra information about OS version, server version, standalone program or web application packaging, executable wrapper, etc: Minecraft 1.21.1, SpongeForge is being used as the server Software, Both running on Windows.

To Reproduce Too complicated, not advised. Needs Minecraft-Server knowledge.

haraldk commented 2 hours ago

This is puzzling... TwelveMonkeys has no dependency on snakeyaml, so I'm not sure why this is happening. Are you using some special modified version of the library?