You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Should build macOS native app without initializing during image building.
Actual Behaviour
I got an error: Classes that should be initialized at run time got initialized during image building: kotlin.coroutines.intrinsics.CoroutineSingletons …
09:40:13: Executing 'nativeBuild'...
Starting Gradle Daemon...
Gradle Daemon started in 686 ms
> Task :generateJte UP-TO-DATE
> Task :compileJava UP-TO-DATE
> Task :compileGroovy NO-SOURCE
> Task :processResources UP-TO-DATE
> Task :classes UP-TO-DATE
> Task :jar UP-TO-DATE
> Task :generateResourcesConfigFile UP-TO-DATE
> Task :nativeCompile
[native-image-plugin] GraalVM Toolchain detection is disabled
[native-image-plugin] GraalVM location read from environment variable: JAVA_HOME
[native-image-plugin] Native Image executable path: /Users/kuba/.sdkman/candidates/java/21.0.2-graalce/lib/svm/bin/native-image
========================================================================================================================
GraalVM Native Image: Generating 'demo' (executable)...
========================================================================================================================
For detailed information and explanations on the build output, visit:
https://github.com/oracle/graal/blob/master/docs/reference-manual/native-image/BuildOutput.md
------------------------------------------------------------------------------------------------------------------------
[1/8] Initializing... (7,9s @ 0,27GB)
Java version: 21.0.2+13, vendor version: GraalVM CE 21.0.2+13.1
Graal compiler: optimization level: 2, target machine: armv8-a
C compiler: cc (apple, arm64, 15.0.0)
Garbage collector: Serial GC (max heap size: 80% of RAM)
2 user-specific feature(s):
- com.oracle.svm.thirdparty.gson.GsonFeature
- io.micronaut.core.io.service.ServiceLoaderFeature
------------------------------------------------------------------------------------------------------------------------
Build resources:
- 12,09GB of memory (75,6% of 16,00GB system memory, determined at start)
- 8 thread(s) (100,0% of 8 available processor(s), determined at start)
[2/8] Performing analysis... [*] (73,3s @ 3,69GB)
36 844 reachable types (92,9% of 39 648 total)
59 769 reachable fields (69,2% of 86 405 total)
209 421 reachable methods (67,7% of 309 275 total)
11 157 types, 540 fields, and 7 527 methods registered for reflection
1 native library: -framework CoreServices
------------------------------------------------------------------------------------------------------------------------
33,0s (40,3% of total time) in 93 GCs | Peak RSS: 5,28GB | CPU load: 5,57
========================================================================================================================
Finished generating 'demo' in 1m 21s.
Error: Classes that should be initialized at run time got initialized during image building:
kotlin.coroutines.intrinsics.CoroutineSingletons was unintentionally initialized at build time. To see why kotlin.coroutines.intrinsics.CoroutineSingletons got initialized use --trace-class-initialization=kotlin.coroutines.intrinsics.CoroutineSingletons
To see how the classes got initialized, use --trace-class-initialization=kotlin.coroutines.intrinsics.CoroutineSingletons
> Task :nativeCompile FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':nativeCompile'.
> Process 'command '/Users/kuba/.sdkman/candidates/java/current/bin/native-image'' finished with non-zero exit value 1
* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.
> Get more help at https://help.gradle.org.
BUILD FAILED in 1m 26s
6 actionable tasks: 1 executed, 5 up-to-date
09:41:40: Execution finished 'nativeBuild'.
Expected Behavior
Should build macOS native app without initializing during image building.
Actual Behaviour
I got an error: Classes that should be initialized at run time got initialized during image building: kotlin.coroutines.intrinsics.CoroutineSingletons …
Steps To Reproduce
I created an micronaut 4.4.1 app with
and immediately tried to build a native app.
Environment Information
Example Application
No response
Version
4.4.1
The text was updated successfully, but these errors were encountered: