1
votes

I created web application using play framework. I am trying to use Play Ebean following this guide Java Ebean - 2.6.x - Play Framework. So I copied addSbtPlugin("com.typesafe.sbt" % "sbt-play-ebean" % "4.0.1") into plugins.sbt and modified build.sbt

lazy val myProject = (project in file("."))
  .enablePlugins(PlayJava, PlayEbean)

But while running sbt it says it is unable to resolve dependencies.

[warn] Note: Unresolved dependencies path:
[error] sbt.librarymanagement.ResolveException: Error downloading com.typesafe.sbt:sbt-play-ebean;sbtVersion=1.0;scalaVersion=2.12:4.0.1
[error] Not found
[error] Not found
[error] not found: https://repo1.maven.org/maven2/com/typesafe/sbt/sbt-play-ebean_2.12_1.0/4.0.1/sbt-play-ebean-4.0.1.pom

After reading few other stackoverflow posts link 1, link 2, it seems it is due to unmatched versions. I tried to use sbt-play-ebean 6.1.0, but it didn't work. Second link suggested changing scala version used by sbt, but I can't find how to do that.

2
Use 6.0.0, 6.1.0 not released yet.VM4
@VM4 thank you it worked after using 6.0.0. I thought I had tried that but apparently I didn't. If you would answer it I'd be happy to mark it answered.Kshitij Dhakal

2 Answers

3
votes

6.0.0 is the newest supported version as of today.

1
votes

check the play-ebean site to know which version to use. In your case with Play 2.6.x you may use 4.0.2 -> 4.1.4. The error is actually because the 4.0.1 version is not found in the repo.