我在用
scala 1.12.10
akka 2.6.3
addSbtPlugin("io.spray" % "sbt-revolver" % "0.9.1")
addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "1.1.0")
Run Code Online (Sandbox Code Playgroud)
但是,在执行时sbt assembly我得到:
java.lang.UnsupportedOperationException: The Security Manager is deprecated and will be removed in a future release
at java.base/java.lang.System.setSecurityManager(System.java:416)
at sbt.TrapExit$.installManager(TrapExit.scala:53)
at sbt.StandardMain$.runManaged(Main.scala:109)
at sbt.xMain.run(Main.scala:76)
at xsbt.boot.Launch$$anonfun$run$1.apply(Launch.scala:111)
at xsbt.boot.Launch$.withContextLoader(Launch.scala:131)
at xsbt.boot.Launch$.run(Launch.scala:111)
at xsbt.boot.Launch$$anonfun$apply$1.apply(Launch.scala:37)
at xsbt.boot.Launch$.launch(Launch.scala:120)
at xsbt.boot.Launch$.apply(Launch.scala:20)
at xsbt.boot.Boot$.runImpl(Boot.scala:56)
at xsbt.boot.Boot$.main(Boot.scala:18)
at xsbt.boot.Boot.main(Boot.scala)
[error] [launcher] error during sbt launcher: java.lang.UnsupportedOperationException: The Security Manager is deprecated and will be removed in a future release
Run Code Online (Sandbox Code Playgroud)
运行java …
使用brew和/或brew cask安装java 8和sbt显然是可能的,我遇到的问题是brew安装java 13作为sbt依赖项,
我不知道返回到默认 java 8 的一般方法,因为有很多方法可以在 java 版本之间进行选择,我知道其中一些方法包括 PATH、JAVA_HOME、ln -s、java_exec 选择器。
另一个潜在的问题是brew install sbt安装brew install java,它是13,但是java 8我通过brew cask安装它。
TL 说 Java 13 或 14 可能会导致一些问题,例如测试失败,我应该推送最新版本的 OpenJdk、Scala、SBT 等吗?