Reputation: 7629
I'm new to Play Framework. I've just read about how to create and run a play project. I've been given a project and am facing Error: Could not retrieve sbt 0.11.3
:
Getting org.scala-sbt sbt 0.11.3 ...
:: problems summary ::
:::: WARNINGS
module not found: org.scala-sbt#sbt;0.11.3
==== local: tried
/home/ritesh/Play/play-2.1.0/repository/local/org.scala-sbt/sbt/0.11.3/ivys/ivy.xml
==== Maven2 Local: tried
file:///home/ritesh/.m2/repository/org/scala-sbt/sbt/0.11.3/sbt-0.11.3.pom
==== typesafe-ivy-releases: tried
http://repo.typesafe.com/typesafe/ivy-releases/org.scala-sbt/sbt/0.11.3/ivys/ivy.xml
==== Maven Central: tried
http://repo1.maven.org/maven2/org/scala-sbt/sbt/0.11.3/sbt-0.11.3.pom
::::::::::::::::::::::::::::::::::::::::::::::
:: UNRESOLVED DEPENDENCIES ::
::::::::::::::::::::::::::::::::::::::::::::::
:: org.scala-sbt#sbt;0.11.3: not found
::::::::::::::::::::::::::::::::::::::::::::::
:: USE VERBOSE OR DEBUG MESSAGE LEVEL FOR MORE DETAILS
unresolved dependency: org.scala-sbt#sbt;0.11.3: not found
Error during sbt execution: Error retrieving required libraries
(see /home/ritesh/Play/play-2.1.0/framework/sbt/boot/update.log for complete log)
Error: Could not retrieve sbt 0.11.3
I only installed Play Framework 2.1.0
distribution and nothing else.
How can I get passed the error and execute the play
command successfully?
Upvotes: 9
Views: 13891
Reputation: 1040
It seems you're using play 2.1.0
which is distributed with sbt 0.12.2
.
The solution is not to upgrade your play distribution as you only need to edit your project/build.properties
file and change
sbt.version=0.11.3
to
sbt.version=0.12.2
With the change, the project should be fine.
Upvotes: 6
Reputation: 136
I think your existing project has dependencies to sbt 0.11.3 and you are running it with Play 2.1.0 which uses sbt 0.12.2.
Check the file build.properties located under the project folder. If it says 0.11.3 your project probably uses another Play version and need to be upgraded to 2.1.0.
The sbt-plugin should have Play 2.1.0 assigned - se plugins.sbt under project folder.
Either ugrade your project: http://www.playframework.com/documentation/2.1.0/Migration
Or - switch to an older Play version - the correct for your project. => http://www.playframework.com/download.
Upvotes: 12
Reputation: 11244
Play 2.1 does not come with sbt 0.11.3. Since you are not on a window box I recommend you use sbt-extras. That utility will automatically download the correct version of sbt.
curl https://raw.github.com/paulp/sbt-extras/master/sbt > ~/bin/sbt
chmod +x ~/bin/sbt
And then from within your project directory:
~/bin/sbt
If files in your bin
folder are automatically on the path you can skip the ~/bin/
part.
To work without sbt extras you would need to download the appropriate play version which can be found in the project/plugins.sbt
within the directory of your project.
Upvotes: 0