[error] java.lang.AssertionError: assertion failed: Internal task engine error: nothing running. This usually indicates a cycle in tasks.
[error] Calling tasks (internal task engine state):
[error] Task((task-definition-key: ScopedKey(Scope(Select(ProjectRef(file:/home/aleveugl/workspace/utils-univers-core/,utils-univers-core)),Global,Global,Global),play-package-everything))) -> Calling
[error] Use 'last' for the full log.
[utils-univers-core] $ last
[debug] Running task... Cancelable: false, check cycles: false
[info] Wrote /home/aleveugl/workspace/utils-univers-core/target/scala-2.10/utils-univers-core_2.10-3.0.2-SNAPSHOT.pom
[info] Updating {file:/home/aleveugl/workspace/utils-univers-core/}utils-univers-core...
[info] Done updating.
java.lang.AssertionError: assertion failed: Internal task engine error: nothing running. This usually indicates a cycle in tasks.
Calling tasks (internal task engine state):
Task((task-definition-key: ScopedKey(Scope(Select(ProjectRef(file:/home/aleveugl/workspace/utils-univers-core/,utils-univers-core)),Global,Global,Global),play-package-everything))) -> Calling
at scala.Predef$.assert(Predef.scala:160)
at sbt.Execute$$anonfun$next$1$1.apply$mcV$sp(Execute.scala:81)
at sbt.Execute.pre(Execute.scala:349)
at sbt.Execute.next$1(Execute.scala:77)
at sbt.Execute.processAll(Execute.scala:88)
at sbt.Execute.runKeep(Execute.scala:68)
at sbt.EvaluateTask$.run$1(EvaluateTask.scala:162)
at sbt.EvaluateTask$.runTask(EvaluateTask.scala:177)
at sbt.Aggregation$$anonfun$4.apply(Aggregation.scala:46)
at sbt.Aggregation$$anonfun$4.apply(Aggregation.scala:44)
at sbt.EvaluateTask$.withStreams(EvaluateTask.scala:137)
at sbt.Aggregation$.runTasksWithResult(Aggregation.scala:44)
at sbt.Aggregation$.runTasks(Aggregation.scala:59)
at sbt.Aggregation$$anonfun$applyTasks$1.apply(Aggregation.scala:31)
at sbt.Aggregation$$anonfun$applyTasks$1.apply(Aggregation.scala:30)
at sbt.Command$$anonfun$applyEffect$2$$anonfun$apply$3.apply(Command.scala:62)
at sbt.Command$$anonfun$applyEffect$2$$anonfun$apply$3.apply(Command.scala:62)
at sbt.Command$.process(Command.scala:90)
at sbt.MainLoop$$anonfun$next$1$$anonfun$apply$1.apply(MainLoop.scala:71)
at sbt.MainLoop$$anonfun$next$1$$anonfun$apply$1.apply(MainLoop.scala:71)
at sbt.State$$anon$2.process(State.scala:170)
at sbt.MainLoop$$anonfun$next$1.apply(MainLoop.scala:71)
at sbt.MainLoop$$anonfun$next$1.apply(MainLoop.scala:71)
at sbt.ErrorHandling$.wideConvert(ErrorHandling.scala:18)
at sbt.MainLoop$.next(MainLoop.scala:71)
at sbt.MainLoop$.run(MainLoop.scala:64)
at sbt.MainLoop$$anonfun$runWithNewLog$1.apply(MainLoop.scala:53)
at sbt.MainLoop$$anonfun$runWithNewLog$1.apply(MainLoop.scala:50)
at sbt.Using.apply(Using.scala:25)
at sbt.MainLoop$.runWithNewLog(MainLoop.scala:50)
at sbt.MainLoop$.runAndClearLast(MainLoop.scala:33)
at sbt.MainLoop$.runLoggedLoop(MainLoop.scala:17)
at sbt.MainLoop$.runLogged(MainLoop.scala:13)
at sbt.xMain.run(Main.scala:26)
at xsbt.boot.Launch$.run(Launch.scala:55)
at xsbt.boot.Launch$$anonfun$explicit$1.apply(Launch.scala:45)
at xsbt.boot.Launch$.launch(Launch.scala:69)
at xsbt.boot.Launch$.apply(Launch.scala:16)
at xsbt.boot.Boot$.runImpl(Boot.scala:31)
at xsbt.boot.Boot$.main(Boot.scala:20)
at xsbt.boot.Boot.main(Boot.scala)
[error] java.lang.AssertionError: assertion failed: Internal task engine error: nothing running. This usually indicates a cycle in tasks.
[error] Calling tasks (internal task engine state):
[error] Task((task-definition-key: ScopedKey(Scope(Select(ProjectRef(file:/home/aleveugl/workspace/utils-univers-core/,utils-univers-core)),Global,Global,Global),play-package-everything))) -> Calling
.settings(
publishArtifact in (Compile, packageDoc) := false
)
.settings(addArtifact(Artifact (appName, "dist", "zip"), dist).settings: _*)
.settings(
publishArtifact in (Compile, packageDoc) := false
)
https://github.com/playframework/Play20/pull/535
There is a problem with this new implementation :
In play 2.0.4, when I wanted to publish the zip file containing all the jars, I just had to add the following setting to my build.scala :
.settings(addArtifact(Artifact (appName, "dist", "zip"), dist).settings: _*)
"I believe a better approach is for the "dist" command to take its input from the packagedArtifacts"
So now the dist command is calling the playPackageEverything command which try to build all the artifacts (including my dist zip) -> ERROR :
[error] java.lang.AssertionError: assertion failed: Internal task engine error: nothing running. This usually indicates a cycle in tasks.
[error] Calling tasks (internal task engine state):
So how to publish the zip file ?
I'm using play 2.1-RC2 java.
Thank you for your help.
val distHack = TaskKey[sbt.File]("dist-hack", "Hack to publish dist")
val myDistSettings = Seq[Setting[_]] ( publish <<= (publish) dependsOn play.Project.dist, publishLocal <<= (publishLocal) dependsOn play.Project.dist, artifact in distHack ~= { (art: Artifact) => art.copy(`type` = "zip", extension = "zip") }, distHack <<= (distDirectory, version) map { (d, v) => val packageName = "%s-%s" format(projectName, v) val zip = d / (packageName + ".zip") zip }) ++ Seq(addArtifact(artifact in distHack, distHack).settings: _*)
distPublish <<= (distDirectory, normalizedName, version) map { (distDir, id, version) =>
val packageName = "%s-%s" format(id, version)
distDir / (packageName + ".zip")
},
publishArtifact in (Compile, packageBin) := false,