incOptions := incOptions.value.withNameHashing(true)
in ThisBuild
Hello Grzegorz,
I have a problem running the developer mode (invoked by entering run on play's sbt console) - when I enter the webapp from browser I get
play.PlayExceptions$UnexpectedException: Unexpected exception[UnsupportedOperationException: The `++` operation is not supported for relations with different values of `nameHashing` flag.]
I have configured the project according to instructions and the compile times are lower: "adding method to controller" and "adding a route to routes file" have changed from 12 to 7 seconds and 19 to 16 respectively on my 2.2.1 project. One strange thing though - when hit I compile when I changed nothing it takes 6 seconds compared to 1 second on sbt 0.13
Thanks, couple of observations out of the box:
1) after a clean/compile (3 in fact, wanted to see if any build time improvement) ~run surprsingly triggers another compilation (or 2)
2) seems pretty borken (broken) for sub projects, does the exact opposite, slows things waaaaay down as a single change to a subproject X controller triggers recompilation of all other subprojects -- yikes bad memories of pre-sub project days ;-)
Not sure if I'm missing something, have this in my parent aggregator project section of Buiuld.scala:
incOptions := incOptions.value.withNameHashing(true)
Maybe the above needs anor apply it to all sub project .settings(...)?
in ThisBuild
Thanks! Subprojects - this is it! I have another problem though: after having modified build.sbt for every subproject (build.properties as well but I don't think that is required), I getjava.lang.UnsupportedOperationException: The `memberRef` source dependencies relation is not supported when `nameHashing` flag is disabled.
Re 6 seconds: There was no message other than standard [success] Total time 6 sec. so I guess there no file was compiled.
incOptions := incOptions.value.withNameHashing(true)
java.lang.UnsupportedOperationException: The `memberRef` source dependencies relation is not supported when `nameHashing` flag is disabled
java.lang.UnsupportedOperationException: The `memberRef` source dependencies relation is not supported when `nameHashing` flag is disabled.
at sbt.inc.MRelationsDefaultImpl.inheritance(Relations.scala:333)
at sbt.inc.IncrementalNameHashing.invalidatedPackageObjects(Incremental.scala:503)
at sbt.inc.IncrementalCommon.cycle(Incremental.scala:88)
at sbt.inc.Incremental$$anonfun$1.apply(Incremental.scala:38)
at sbt.inc.Incremental$$anonfun$1.apply(Incremental.scala:37)
at sbt.inc.Incremental$.manageClassfiles(Incremental.scala:58)
at sbt.inc.Incremental$.compile(Incremental.scala:37)
at sbt.inc.IncrementalCompile$.apply(Compile.scala:27)
at sbt.compiler.AggressiveCompile.compile2(AggressiveCompile.scala:150)
at sbt.compiler.AggressiveCompile.compile1(AggressiveCompile.scala:70)
at sbt.compiler.AggressiveCompile.apply(AggressiveCompile.scala:45)
at sbt.Compiler$.apply(Compiler.scala:70)
at sbt.Defaults$.sbt$Defaults$$compileTaskImpl(Defaults.scala:741)
at sbt.Defaults$$anonfun$compileTask$1.apply(Defaults.scala:735)
at sbt.Defaults$$anonfun$compileTask$1.apply(Defaults.scala:735)
at scala.Function1$$anonfun$compose$1.apply(Function1.scala:47)
at sbt.$tilde$greater$$anonfun$$u2219$1.apply(TypeFunctions.scala:42)
at sbt.std.Transform$$anon$4.work(System.scala:64)
at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:237)
at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:237)
at sbt.ErrorHandling$.wideConvert(ErrorHandling.scala:18)
at sbt.Execute.work(Execute.scala:244)
at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:237)
at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:237)
at sbt.ConcurrentRestrictions$$anon$4$$anonfun$1.apply(ConcurrentRestrictions.scala:160)
at sbt.CompletionService$$anon$2.call(CompletionService.scala:30)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:722)
--
You received this message because you are subscribed to a topic in the Google Groups "play-framework" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/play-framework/S_-wYW5Tcvw/unsubscribe.
To unsubscribe from this group and all its topics, send an email to play-framewor...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
For show incOptions each subproject has:
IncOptions(3,0.5,false,false,5,None,<function0>,true,true)
Somehow the application compiles now o_O
The surprising behaviors remain, however:
1) after a ;clean;compile, ~run triggers another compile (does not occur on < 0.13.2)
2) changing a controller in subproject X triggers the recompilation of all subprojects
#2 is particularly painful, basically negates one of the primary benefits of using subprojects.
BTW, application is Play 2.2.1, 10 subprojects, all play.Projects (i.e. no pure sbt Projects)
Had a similar issue with subprojects and SBT native packaging manager that Play swtiched to with the 2.2 branch. Hopefully there's quick fix in there to address this issue. Would like to take it for a spin as full ;clean;compile cycles are about 10% faster, and incremental improvements to boot would make for some nice WIN ;-)
Thanks for pushing scalac performance forward.
Hi Grzegorz,I noticed that the additional recompilation of all views after every compile was connected with upgrading sbt from version 0.13.0 (I observed the same behaviour in sbt 0.13.1). It looks like play must be changed to avoid it, (possibly done in 2.2.2RC1, I haven't tested it).Thanks for speeding efforts, much appreciated!
--
You received this message because you are subscribed to a topic in the Google Groups "play-framework" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/play-framework/S_-wYW5Tcvw/unsubscribe.
To unsubscribe from this group and all its topics, send an email to play-framewor...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
You received this message because you are subscribed to the Google Groups "play-framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email to play-framewor...@googlegroups.com.
I did restart sbt - exit. I also tried cleaning the build project targets by hand - ; reload plugins; clean; compile;When I initially run 'sbt clean compile', success-the build completes successfully, and all lights are green. If I then run 'sbt compile', this error occurs.Hello Grzegorz,
I also killed the target folder in the affected project by hand.No luck- the second compile is enough that this stacktrace occurs again. What can I provide that might assist further troubleshooting?