我试图将我的播放应用程序从版本2.3.10迁移到2.4(我使用Java)。我跟随了播放主页上的迁移指南,但是sbt出现了错误。到目前为止我做了什么: - 将build.sbt中的scala版本更改为2.11.6 - 在plugins.sbt中将播放版本更改为2.4.0 - 将build.properties中的sbt.version更改为0.13.8
在build.sbt刷新后,我收到以下错误:
java.lang.RuntimeException: No project '...' in 'file:/...'.Valid project IDs: root
at scala.sys.package$.error(package.scala:27)
at sbt.Load$$anonfun$checkAll$2$$anonfun$apply$13.apply(Load.scala:370)
at sbt.Load$$anonfun$checkAll$2$$anonfun$apply$13.apply(Load.scala:365)
at scala.collection.immutable.List.foreach(List.scala:318)
at sbt.Load$$anonfun$checkAll$2.apply(Load.scala:365)
at sbt.Load$$anonfun$checkAll$2.apply(Load.scala:365)
at scala.collection.TraversableLike$WithFilter$$anonfun$foreach$1.apply(TraversableLike.scala:772)
at scala.collection.immutable.Map$Map1.foreach(Map.scala:109)
at scala.collection.TraversableLike$WithFilter.foreach(TraversableLike.scala:771)
at sbt.Load$.checkAll(Load.scala:365)
at sbt.Load$.loadURI(Load.scala:290)
at sbt.Load$.load(Load.scala:285)
at sbt.Load$.load(Load.scala:276)
at sbt.Load$.apply(Load.scala:130)
at sbt.Load$.defaultLoad(Load.scala:36)
at sbt.BuiltinCommands$.doLoadProject(Main.scala:481)
at sbt.BuiltinCommands$$anonfun$loadProjectImpl$2.apply(Main.scala:475)
at sbt.BuiltinCommands$$anonfun$loadProjectImpl$2.apply(Main.scala:475)
at sbt.Command$$anonfun$applyEffect$1$$anonfun$apply$2.apply(Command.scala:58)
at sbt.Command$$anonfun$applyEffect$1$$anonfun$apply$2.apply(Command.scala:58)
at sbt.Command$$anonfun$applyEffect$2$$anonfun$apply$3.apply(Command.scala:60)
at sbt.Command$$anonfun$applyEffect$2$$anonfun$apply$3.apply(Command.scala:60)
at sbt.Command$.process(Command.scala:92)
at sbt.MainLoop$$anonfun$1$$anonfun$apply$1.apply(MainLoop.scala:98)
at sbt.MainLoop$$anonfun$1$$anonfun$apply$1.apply(MainLoop.scala:98)
at sbt.State$$anon$1.process(State.scala:184)
at sbt.MainLoop$$anonfun$1.apply(MainLoop.scala:98)
at sbt.MainLoop$$anonfun$1.apply(MainLoop.scala:98)
at sbt.ErrorHandling$.wideConvert(ErrorHandling.scala:17)
at sbt.MainLoop$.next(MainLoop.scala:98)
at sbt.MainLoop$.run(MainLoop.scala:91)
at sbt.MainLoop$$anonfun$runWithNewLog$1.apply(MainLoop.scala:70)
at sbt.MainLoop$$anonfun$runWithNewLog$1.apply(MainLoop.scala:65)
at sbt.Using.apply(Using.scala:24)
at sbt.MainLoop$.runWithNewLog(MainLoop.scala:65)
at sbt.MainLoop$.runAndClearLast(MainLoop.scala:48)
at sbt.MainLoop$.runLoggedLoop(MainLoop.scala:32)
at sbt.MainLoop$.runLogged(MainLoop.scala:24)
at sbt.StandardMain$.runManaged(Main.scala:53)
at sbt.xMain.run(Main.scala:28)
at xsbt.boot.Launch$$anonfun$run$1.apply(Launch.scala:57)
at xsbt.boot.Launch$.withContextLoader(Launch.scala:77)
at xsbt.boot.Launch$.run(Launch.scala:57)
at xsbt.boot.Launch$$anonfun$explicit$1.apply(Launch.scala:45)
at xsbt.boot.Launch$.launch(Launch.scala:65)
at xsbt.boot.Launch$.apply(Launch.scala:16)
at xsbt.boot.Boot$.runImpl(Boot.scala:32)
at xsbt.boot.Boot$.main(Boot.scala:21)
at xsbt.boot.Boot.main(Boot.scala)
似乎sbt无法找到子项目,但我不知道如何解决这个错误。顺便说一下,应用程序可以在2.3.10上无缝地工作。
我希望有人可以帮助我!提前谢谢。
答案 0 :(得分:0)
答案 1 :(得分:0)
尝试将这些添加到 plugins.sbt 文件;
resolvers += "Typesafe repository" at "http://repo.typesafe.com/typesafe/releases/"
// The Play plugin
addSbtPlugin("com.typesafe.play" % "sbt-plugin" % "2.4.3")
我建议您使用2.4.3如果您要升级您的Play版本,它应该是最新版本。此外,请遵循这个guideline,而不是你应该没事。