Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

sbt does not resolve Typesafe repository

I have an odd problem with sbt and the Typesafe repository:

[info] Resolving com.typesafe.play#play-json_2.10;2.2.0 ...
[warn]  module not found: com.typesafe.play#play-json_2.10;2.2.0
[warn] ==== local: tried
[warn]   /Users/hhrutz/.ivy2/local/com.typesafe.play/play-json_2.10/2.2.0/ivys/ivy.xml
[warn] ==== public: tried
[warn]   http://repo1.maven.org/maven2/com/typesafe/play/play-json_2.10/2.2.0/play-json_2.10-2.2.0.pom
[warn] ==== Typesafe Releases: tried
[warn]   https://repo.typesafe.com/typesafe/releases/com/typesafe/play/play-json_2.10/2.2.0/play-json_2.10-2.2.0.pom
[info] Resolving org.fusesource.jansi#jansi;1.4 ...
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[warn]  ::          UNRESOLVED DEPENDENCIES         ::
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[warn]  :: com.typesafe.play#play-json_2.10;2.2.0: not found
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
sbt.ResolveException: unresolved dependency: com.typesafe.play#play-json_2.10;2.2.0: not found

I can manually download both .pom and .jar from http://repo.typesafe.com/typesafe/releases/com/typesafe/play/play-json_2.10/2.2.0/ so the server is definitely there.

Is this perhaps an sbt problem? Any clues why it would fail if it definitely has the right URL?

like image 661
0__ Avatar asked Dec 10 '13 14:12

0__


People also ask

Where are SBT dependencies stored?

If you have JAR files (unmanaged dependencies) that you want to use in your project, simply copy them to the lib folder in the root directory of your SBT project, and SBT will find them automatically.

Where is SBT local repository?

The publishLocal action is used to publish your project to your Ivy local file repository, which is usually located at $HOME/. ivy2/local/ . You can then use this project from other projects on the same machine.


2 Answers

It seems there is an unknown problem with the resolver

resolvers += "Typesafe Releases" at "https://repo.typesafe.com/typesafe/releases/"

Finding this question, the problem can be solved by adding yet another resolver:

resolvers += "Typesafe Simple Repository" at
  "http://repo.typesafe.com/typesafe/simple/maven-releases/"
like image 139
0__ Avatar answered Sep 18 '22 08:09

0__


For people facing this issue in 2020 onwards, please replace http part with https in resolver url.

Ref: https://www.lightbend.com/blog/lightbend-to-require-https-on-repos-starting-august-5-2020

like image 33
Ravinder Payal Avatar answered Sep 20 '22 08:09

Ravinder Payal