mircokroon / minecraft-world-downloader

Download Minecraft worlds, extend server's render distance. 1.12.2 - 1.21
GNU General Public License v3.0
1.25k stars 82 forks source link

javafx.fxml.LoadException #697

Open TiAM0 opened 1 month ago

TiAM0 commented 1 month ago

When started from command line and from the minimap right click and trying to open the settings menu I get an JavaFX error

And when trying to start it into GUI directly I get this error:

Sept 14, 2024 10:49:57 AM com.sun.javafx.application.PlatformImpl startup WARNING: Unsupported JavaFX configuration: classes were loaded from 'unnamed module @71e7a66b'

javafx.fxml.LoadException: file:/C:/world-download/world-downloader.jar!/ui/Settings.fxml

    at javafx.fxml.FXMLLoader.constructLoadException(FXMLLoader.java:2707)
    at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2677)
    at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2548)
    at javafx.fxml.FXMLLoader.load(FXMLLoader.java:2516)
    at gui.GuiManager.loadScene(GuiManager.java:203)
    at gui.GuiManager.loadScene(GuiManager.java:196)
    at gui.GuiManager.loadSceneOrLaunch(GuiManager.java:187)
    at gui.GuiManager.loadSceneSettings(GuiManager.java:65)
    at gui.GuiManager.start(GuiManager.java:299)
    at com.sun.javafx.application.LauncherImpl.lambda$launchApplication1$9(LauncherImpl.java:847)
    at com.sun.javafx.application.PlatformImpl.lambda$runAndWait$12(PlatformImpl.java:484)
    at com.sun.javafx.application.PlatformImpl.lambda$runLater$10(PlatformImpl.java:457)
    at java.base/java.security.AccessController.doPrivileged(AccessController.java:400)
    at com.sun.javafx.application.PlatformImpl.lambda$runLater$11(PlatformImpl.java:456)
    at com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:96)
    at com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
    at com.sun.glass.ui.win.WinApplication.lambda$runLoop$3(WinApplication.java:184)
    at java.base/java.lang.Thread.run(Thread.java:1583)

Caused by: 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 com.sun.javafx.reflect.Trampoline.invoke(MethodUtil.java:77) at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103) at java.base/java.lang.reflect.Method.invoke(Method.java:580) at com.sun.javafx.reflect.MethodUtil.invoke(MethodUtil.java:275) at com.sun.javafx.fxml.MethodHelper.invoke(MethodHelper.java:84) at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2673) ... 16 more Caused by: proxy.auth.MinecraftAuthenticationException: Cannot get Microsoft token. Status: 400 at proxy.auth.MicrosoftAuthHandler.acquireMicrosoftToken(MicrosoftAuthHandler.java:104) at proxy.auth.MicrosoftAuthHandler.refresh(MicrosoftAuthHandler.java:63) at proxy.auth.MicrosoftAuthHandler.getAuthDetails(MicrosoftAuthHandler.java:182) at proxy.auth.AuthDetailsManager.retrieveDetailsFromMicrosoft(AuthDetailsManager.java:31) at proxy.auth.AuthDetailsManager.loadAuthDetails(AuthDetailsManager.java:43) at proxy.auth.AuthDetailsManager.validateAuthStatus(AuthDetailsManager.java:50) at gui.GuiSettings.validateAuth(GuiSettings.java:378) at gui.GuiSettings.initialize(GuiSettings.java:168) at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103) ... 23 more

T1AM0 commented 1 month ago

I tried to install the javafx but still the same issue, but with different errors, tried it on two different computers, one with a clean install of windows and java:

set PATH_TO_FX="C:\Program Files\Java\javafx-sdk-23\lib" F:\world-download>java --module-path %PATH_TO_FX% --add-modules javafx.controls,javafx.fxml,javafx.graphics,javafx.base -jar world-downloader.jar

{"error":"invalid_grant","error_description":"The user could not be authenticated as the grant is expired. The user must sign in again.","correlation_id":"XXXXX"} javafx.fxml.LoadException: file:/F:/world-download/world-downloader.jar!/ui/Settings.fxml

    at javafx.fxml@23/javafx.fxml.FXMLLoader.constructLoadException(FXMLLoader.java:2727)
    at javafx.fxml@23/javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2697)
    at javafx.fxml@23/javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2568)
    at javafx.fxml@23/javafx.fxml.FXMLLoader.load(FXMLLoader.java:2536)
    at gui.GuiManager.loadScene(GuiManager.java:203)
    at gui.GuiManager.loadScene(GuiManager.java:196)
    at gui.GuiManager.loadSceneOrLaunch(GuiManager.java:187)
    at gui.GuiManager.loadSceneSettings(GuiManager.java:65)
    at gui.GuiManager.start(GuiManager.java:299)
    at javafx.graphics@23/com.sun.javafx.application.LauncherImpl.lambda$launchApplication1$9(LauncherImpl.java:839)
    at javafx.graphics@23/com.sun.javafx.application.PlatformImpl.lambda$runAndWait$12(PlatformImpl.java:483)
    at javafx.graphics@23/com.sun.javafx.application.PlatformImpl.lambda$runLater$10(PlatformImpl.java:456)
    at java.base/java.security.AccessController.doPrivileged(AccessController.java:400)
    at javafx.graphics@23/com.sun.javafx.application.PlatformImpl.lambda$runLater$11(PlatformImpl.java:455)
    at javafx.graphics@23/com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:95)
    at javafx.graphics@23/com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
    at javafx.graphics@23/com.sun.glass.ui.win.WinApplication.lambda$runLoop$3(WinApplication.java:184)
    at java.base/java.lang.Thread.run(Thread.java:1583)

Caused by: 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 com.sun.javafx.reflect.Trampoline.invoke(MethodUtil.java:72) at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103) at java.base/java.lang.reflect.Method.invoke(Method.java:580) at javafx.base@23/com.sun.javafx.reflect.MethodUtil.invoke(MethodUtil.java:270) at javafx.fxml@23/com.sun.javafx.fxml.MethodHelper.invoke(MethodHelper.java:84) at javafx.fxml@23/javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2693) ... 16 more Caused by: proxy.auth.MinecraftAuthenticationException: Cannot get Microsoft token. Status: 400 at proxy.auth.MicrosoftAuthHandler.acquireMicrosoftToken(MicrosoftAuthHandler.java:104) at proxy.auth.MicrosoftAuthHandler.refresh(MicrosoftAuthHandler.java:63) at proxy.auth.MicrosoftAuthHandler.getAuthDetails(MicrosoftAuthHandler.java:182) at proxy.auth.AuthDetailsManager.retrieveDetailsFromMicrosoft(AuthDetailsManager.java:31) at proxy.auth.AuthDetailsManager.loadAuthDetails(AuthDetailsManager.java:43) at proxy.auth.AuthDetailsManager.validateAuthStatus(AuthDetailsManager.java:50) at gui.GuiSettings.validateAuth(GuiSettings.java:378) at gui.GuiSettings.initialize(GuiSettings.java:168) at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103) ... 23 more

T1AM0 commented 1 month ago

Is there a CLI way to auth with microsoft ? so I don't have to use the broken Menu-GUI, the minimap part of the GUI works perfectly.