Got this mysterious error when trying to build a scala play solution containing multiple projects (common projects which the play projects had dependencies on):

[error] {file:/mnt/jenkins/workspace/myproj/}mysubproj/compile:sources: java.util.NoSuchElementException: Either.left.value on Right

Turned out the problem was I hadn't specified the scala version for the common projects, so they were being built with scala 2.9.2 while the play projects tried to build with 2.9.1, causing the issue.

Fixed it by specifying the scala version for all projects in my Build.scala:

scalaVersion := "2.9.1"