oracle / graal

GraalVM compiles Java applications into native executables that start instantly, scale fast, and use fewer compute resources 🚀
https://www.graalvm.org
Other
20.39k stars 1.64k forks source link

[Windows/GitHub] Runtime reflection is not supported for public final void javafx.scene.layout.VBox.setFillWidth(boolean) #4432

Closed st4s1k closed 2 years ago

st4s1k commented 2 years ago

Expected Behavior

Application should run without any issues as in my previous release

Current Behavior

[INFO]
[INFO] ---------------------< com.st4s1k:LeagueTeamComp >----------------------
[INFO] Building LeagueTeamComp 12.5.1
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- gluonfx-maven-plugin:1.0.12:nativerun (default-cli) @ LeagueTeamComp ---
Configuration: ProjectConfiguration{graalPath='C:\Program Files\Java\graalvm-svm-java17-windows-gluon-22.0.0.3-Final', javaStaticSdkVersion='18-ea+prep18-8', javafxStaticSdkVersion='18-ea+10', useJNI=true, useJavaFX=true, usePrismSW=false, enableCheckHash=true, targetTriplet=x86_64-microsoft-windows, hostTriplet=x86_64-microsoft-windows, backend='null', bundlesList=[com.st4s1k.leagueteamcomp.ltc-view], resourcesList=[], reflectionList=[com.st4s1k.leagueteamcomp.controller.LeagueTeamCompController], jniList=[], initBuildTimeList=[], runtimeArgsList=[], releaseSymbolsList=null, appName='LeagueTeamComp', releaseConfiguration='ReleaseConfiguration{packageType=null, description='', vendor='null', version='null', macAppStore=false, macSigningUserName=null, macAppCategory=null, bundleName='null', bundleVersion='null', bundleShortVersion='null', providedSigningIdentity='null', providedProvisioningProfile='null', skipSigning=false, simulatorDevice='null', appLabel='null', versionCode='null', versionName='null', providedKeyStorePath='null', providedKeyStorePassword='null', providedKeyAlias='null', providedKeyAliasPassword='null'}', mainClassName='com.st4s1k.leagueteamcomp.LeagueTeamCompApplication', classpath='D:\MEGA\Plutus\DEV\LeagueTeamComp\target\classes;C:\Users\Stanislav\.m2\repository\com\google\code\gson\gson\2.9.0\gson-2.9.0.jar;C:\Users\Stanislav\.m2\repository\org\controlsfx\controlsfx\11.1.1\controlsfx-11.1.1.jar;C:\Users\Stanislav\.m2\repository\org\openjfx\javafx-base\13.0.2\javafx-base-13.0.2-win.jar;C:\Users\Stanislav\.m2\repository\org\openjfx\javafx-base\13.0.2\javafx-base-13.0.2.jar;C:\Users\Stanislav\.m2\repository\org\openjfx\javafx-controls\13.0.2\javafx-controls-13.0.2-win.jar;C:\Users\Stanislav\.m2\repository\org\openjfx\javafx-controls\13.0.2\javafx-controls-13.0.2.jar;C:\Users\Stanislav\.m2\repository\org\openjfx\javafx-fxml\13.0.2\javafx-fxml-13.0.2-win.jar;C:\Users\Stanislav\.m2\repository\org\openjfx\javafx-fxml\13.0.2\javafx-fxml-13.0.2.jar;C:\Users\Stanislav\.m2\repository\org\openjfx\javafx-graphics\13.0.2\javafx-graphics-13.0.2-win.jar;C:\Users\Stanislav\.m2\repository\org\openjfx\javafx-graphics\13.0.2\javafx-graphics-13.0.2.jar'}
[Sun Mar 27 06:36:16 EEST 2022][INFO] ==================== RUN TASK ====================
[Sun Mar 27 06:36:16 EEST 2022][FINE] PB Command for run until end: D:\MEGA\Plutus\DEV\LeagueTeamComp\target\gluonfx\x86_64-windows\LeagueTeamComp.exe
[Sun Mar 27 06:36:16 EEST 2022][FINE] Start process run until end...
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB] Main
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB] Mar 27, 2022 6:36:17 AM com.sun.javafx.application.PlatformImpl startup
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB] WARNING: Unsupported JavaFX configuration: classes were loaded from 'unnamed module @4e1bf239'
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB] Exception in Application start method
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB] Exception in thread "main" java.lang.RuntimeException: Exception in Application start method
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:901)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.sun.javafx.application.LauncherImpl.lambda$launchApplication$2(LauncherImpl.java:196)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at java.lang.Thread.run(Thread.java:833)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.oracle.svm.core.thread.JavaThreads.threadStartRoutine(JavaThreads.java:597)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.oracle.svm.core.windows.WindowsJavaThreads.osThreadStartRoutine(WindowsJavaThreads.java:140)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB] Caused by: com.oracle.svm.core.jdk.UnsupportedFeatureError: Runtime reflection is not supported for public final void javafx.scene.layout.VBox.setFillWidth(boolean)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.oracle.svm.core.util.VMError.unsupportedFeature(VMError.java:89)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at java.lang.reflect.Method.acquireMethodAccessor(Method.java:91)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at java.lang.reflect.Method.invoke(Method.java:566)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.sun.javafx.fxml.ModuleHelper.invoke(ModuleHelper.java:102)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.sun.javafx.fxml.BeanAdapter.put(BeanAdapter.java:259)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.sun.javafx.fxml.BeanAdapter.put(BeanAdapter.java:54)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at javafx.fxml.FXMLLoader$Element.applyProperty(FXMLLoader.java:523)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at javafx.fxml.FXMLLoader$Element.processValue(FXMLLoader.java:373)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at javafx.fxml.FXMLLoader$Element.processPropertyAttribute(FXMLLoader.java:335)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at javafx.fxml.FXMLLoader$Element.processInstancePropertyAttributes(FXMLLoader.java:245)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at javafx.fxml.FXMLLoader$ValueElement.processEndElement(FXMLLoader.java:778)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at javafx.fxml.FXMLLoader.processEndElement(FXMLLoader.java:2924)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2639)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2548)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:3331)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:3287)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:3255)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:3227)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at javafx.fxml.FXMLLoader.load(FXMLLoader.java:3219)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.st4s1k.leagueteamcomp.LeagueTeamCompApplication.start(LeagueTeamCompApplication.java:46)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.sun.javafx.application.LauncherImpl.lambda$launchApplication1$9(LauncherImpl.java:847)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.sun.javafx.application.PlatformImpl.lambda$runAndWait$12(PlatformImpl.java:484)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.sun.javafx.application.PlatformImpl.lambda$runLater$10(PlatformImpl.java:457)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at java.security.AccessController.doPrivileged(AccessController.java:107)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.sun.javafx.application.PlatformImpl.lambda$runLater$11(PlatformImpl.java:456)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:96)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.oracle.svm.jni.JNIJavaCallWrappers.jniInvoke_VA_LIST_Runnable_run_16403f8d32adb631126daa893e5e80085c5d6325(JNIJavaCallWrappers.java:0)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.sun.glass.ui.win.WinApplication._runLoop(WinApplication.java)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     at com.sun.glass.ui.win.WinApplication.lambda$runLoop$3(WinApplication.java:184)
[Sun Mar 27 06:36:17 EEST 2022][INFO] [SUB]     ... 3 more
[Sun Mar 27 06:36:17 EEST 2022][FINE] Result for run until end: 0
             _______  ___      __   __  _______  __    _
            |       ||   |    |  | |  ||       ||  |  | |
            |    ___||   |    |  | |  ||   _   ||   |_| |
            |   | __ |   |    |  |_|  ||  | |  ||       |
            |   ||  ||   |___ |       ||  |_|  ||  _    |
            |   |_| ||       ||       ||       || | |   |
            |_______||_______||_______||_______||_|  |__|

    Access to the latest docs, tips and tricks and more info on
    how to get support? Register your usage of Gluon Substrate now at

    https://gluonhq.com/activate

[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  01:37 min
[INFO] Finished at: 2022-03-27T06:36:18+03:00
[INFO] ------------------------------------------------------------------------

Steps to Reproduce

<VBox alignment="TOP_CENTER" fillWidth="false">

Your Environment

https://github.com/st4s1k/League-of-Legends-Team-Composition-Tool/blob/master/.github/workflows/windows.yml

kkriske commented 2 years ago

This is probably an issue with Gluon Substrate, not GraalVM. Gluon does not claim it provides all the config you may need and states that you may still need to run the native-image-agent, from the docs (https://docs.gluonhq.com/#_gluonfxrunagent): This goal is not strictly needed, as the GluonFX plugin already provides a basic set of configuration files.

So either provide the additional required config yourself, or create an issue on the substrate GitHub page to request it to be added to the default config list.

st4s1k commented 2 years ago

Yeah, you're right, sorry I didn't know which one caused the problem gluon or graalvm. Thanks.

rodrigar-mx commented 2 years ago

Hi @st4s1k. Yes, this should be solved running the native-image-agent from gluon and providing the required reflection config. Feel free to reopen this issue if after completing the suggested steps the issue persists.

cleversonlira commented 2 years ago

@st4s1k Did you manage to solve this problem? I have a similar bug.

st4s1k commented 2 years ago

@cleversonlira https://github.com/gluonhq/substrate/issues/1130