Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error running Native Image binary for Scala 3 backend project #8

Closed
carlosedp opened this issue Oct 14, 2022 · 0 comments
Closed

Error running Native Image binary for Scala 3 backend project #8

carlosedp opened this issue Oct 14, 2022 · 0 comments

Comments

@carlosedp
Copy link
Owner

Due to bugs in the compiler, the backend have been temporarily reverted to Scala 2.13 since Scala 3 doesn't play well with GraalVM Native Image yet.

The error is:

❯ /Users/cdepaula/repos/scala-playground/zio-scalajs-stack/out/backend/nativeImage.dest/backend
Exception in thread "main" scala.runtime.LazyVals$$anon$1
	at scala.runtime.LazyVals$.$init$$$anonfun$3(LazyVals.scala:18)
	at scala.Option.getOrElse(Option.scala:201)
	at scala.runtime.LazyVals$.<clinit>(LazyVals.scala:19)
	at zio.ZLayer.<clinit>(ZLayer.scala:42)
	at java.lang.Class.ensureInitialized(DynamicHub.java:525)
	at zio.ZLayer$Suspend$.apply(ZLayer.scala:437)
	at zio.ZLayer$.suspend(ZLayer.scala:667)
	at zio.ZLayer$.fromZIOEnvironment(ZLayer.scala:613)
	at zio.ZLayer$.<clinit>(ZLayer.scala:558)
	at zio.ZIOAppDefault.$init$(ZIOAppDefault.scala:43)
	at com.carlosedp.zioscalajs.backend.MainApp$.<clinit>(MainApp.scala:11)
	at com.carlosedp.zioscalajs.backend.MainApp.main(MainApp.scala)

Ref:
scala/scala3#13985
scala/scala3#9013
https://www.reddit.com/r/scala/comments/rzvkmi/graalvm_nativeimage_with_scala_3_reflection_hell/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant