gpt4 book ai didi

scala - 玩! dist 抛出异常

转载 作者:行者123 更新时间:2023-12-01 09:56:07 24 4
gpt4 key购买 nike

我正在尝试创建我的 Play 的独立版本!应用程序,当我执行 play run 时它工作正常,但在执行 play dist

之后

当我运行 start 命令时出现以下错误

我正在使用 play2.1 和 Scala 2.10.0

Oops, cannot start the server.@6e25l921m: Cannot init the Global object    at play.api.WithDefaultGlobal$$anonfun$play$api$WithDefaultGlobal$$globalInstance$1.apply(Application.scala:57)    at play.api.WithDefaultGlobal$$anonfun$play$api$WithDefaultGlobal$$globalInstance$1.apply(Application.scala:51)    at play.utils.Threads$.withContextClassLoader(Threads.scala:18)    at play.api.WithDefaultGlobal$class.play$api$WithDefaultGlobal$$globalInstance(Application.scala:50)    at play.api.DefaultApplication.play$api$WithDefaultGlobal$$globalInstance$lzycompute(Application.scala:383)    at play.api.DefaultApplication.play$api$WithDefaultGlobal$$globalInstance(Application.scala:383)    at play.api.WithDefaultGlobal$class.global(Application.scala:66)    at play.api.DefaultApplication.global(Application.scala:383)    at play.api.WithDefaultConfiguration$class.play$api$WithDefaultConfiguration$$fullConfiguration(Application.scala:80)    at play.api.DefaultApplication.play$api$WithDefaultConfiguration$$fullConfiguration$lzycompute(Application.scala:383)    at play.api.DefaultApplication.play$api$WithDefaultConfiguration$$fullConfiguration(Application.scala:383)    at play.api.WithDefaultConfiguration$class.configuration(Application.scala:82)    at play.api.DefaultApplication.configuration(Application.scala:383)    at play.api.Application$class.$init$(Application.scala:268)    at play.api.DefaultApplication.(Application.scala:383)    at play.core.StaticApplication.(ApplicationProvider.scala:52)    at play.core.server.NettyServer$.createServer(NettyServer.scala:228)    at play.core.server.NettyServer$$anonfun$main$5.apply(NettyServer.scala:259)    at play.core.server.NettyServer$$anonfun$main$5.apply(NettyServer.scala:258)    at scala.Option.map(Option.scala:145)    at play.core.server.NettyServer$.main(NettyServer.scala:258)    at play.core.server.NettyServer.main(NettyServer.scala)Caused by: java.lang.NoSuchMethodError: com.typesafe.config.ConfigFactory.load(Lcom/typesafe/config/ConfigParseOptions;)Lcom/typesafe/config/Config;    at play.api.Configuration$.dontAllowMissingConfig$lzycompute(Configuration.scala:25)    at play.api.Configuration$.dontAllowMissingConfig(Configuration.scala:25)    at play.api.Configuration$.load(Configuration.scala:59)    at play.api.WithDefaultConfiguration$$anonfun$initialConfiguration$1.apply(Application.scala:74)    at play.api.WithDefaultConfiguration$$anonfun$initialConfiguration$1.apply(Application.scala:74)    at play.utils.Threads$.withContextClassLoader(Threads.scala:18)    at play.api.WithDefaultConfiguration$class.initialConfiguration(Application.scala:73)    at play.api.DefaultApplication.initialConfiguration$lzycompute(Application.scala:383)    at play.api.DefaultApplication.initialConfiguration(Application.scala:383)    at play.api.WithDefaultGlobal$class.play$api$WithDefaultGlobal$$globalClass(Application.scala:24)    at play.api.DefaultApplication.play$api$WithDefaultGlobal$$globalClass$lzycompute(Application.scala:383)    at play.api.DefaultApplication.play$api$WithDefaultGlobal$$globalClass(Application.scala:383)    at play.api.WithDefaultGlobal$class.play$api$WithDefaultGlobal$$javaGlobal(Application.scala:30)    at play.api.DefaultApplication.play$api$WithDefaultGlobal$$javaGlobal$lzycompute(Application.scala:383)    at play.api.DefaultApplication.play$api$WithDefaultGlobal$$javaGlobal(Application.scala:383)    at play.api.WithDefaultGlobal$$anonfun$play$api$WithDefaultGlobal$$globalInstance$1.apply(Application.scala:52)    ... 21 more

最佳答案

我遇到了同样的问题。确切的解决方法是从

"org.skife.com.typesafe.config" % "typesafe-config" % "0.3.0"

"com.typesafe" % "config" % "1.0.0"

关于scala - 玩! dist 抛出异常,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/16031114/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com