2

Scala、giter8、sbt(0.11.3)、およびmavenのHomebrewの新規インストールを取得し、ほとんどすべてがチェックアウトされます。brew doctorは、pcreとpython2.7を手動でインストールして作成した既知のmodを表示します。play-scalaテンプレートを取得して初めて実行すると、slf4jで次の未解決のdepsが取得されます。

# sudo sbt run
...
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::                                 
[warn]  ::          UNRESOLVED DEPENDENCIES         ::
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[warn]  :: org.slf4j#slf4j-api;1.6.1: configuration not found in org.slf4j#slf4j-api;1.6.1: 'compile'. It was required from org.hibernate#hibernate-validator;4.2.0.Final compile
[warn]  :: commons-codec#commons-codec;1.4: configuration not found in commons-codec#commons-codec;1.4: 'compile'. It was required from org.apache.httpcomponents#httpclient;4.1.2 compile
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[error] {file:/Users/homedir/typesafe/my_app/}my_app/:update: sbt.ResolveException: unresolved dependency: org.slf4j#slf4j-api;1.6.1: configuration not found in org.slf4j#slf4j-api;1.6.1: 'compile'. It was required from org.hibernate#hibernate-validator;4.2.0.Final compile
[error] unresolved dependency: commons-codec#commons-codec;1.4: configuration not found in commons-codec#commons-codec;1.4: 'compile'. It was required from org.apache.httpcomponents#httpclient;4.1.2 compile
[warn] some of the dependencies were not recompiled properly, so classloader is not avaialable
[info] Updating {file:/Users/homedir/typesafe/my_app/}my_app...
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::                                 
[warn]  ::          UNRESOLVED DEPENDENCIES         ::
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[warn]  :: org.slf4j#slf4j-api;1.6.1: configuration not found in org.slf4j#slf4j-api;1.6.1: 'compile'. It was required from org.hibernate#hibernate-validator;4.2.0.Final compile
[warn]  :: commons-codec#commons-codec;1.4: configuration not found in commons-codec#commons-codec;1.4: 'compile'. It was required from org.apache.httpcomponents#httpclient;4.1.2 compile
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[error] {file:/Users/homedir/typesafe/my_app/}my_app/:update: sbt.ResolveException: unresolved dependency: org.slf4j#slf4j-api;1.6.1: configuration not found in org.slf4j#slf4j-api;1.6.1: 'compile'. It was required from org.hibernate#hibernate-validator;4.2.0.Final compile
[error] unresolved dependency: commons-codec#commons-codec;1.4: configuration not found in commons-codec#commons-codec;1.4: 'compile'. It was required from org.apache.httpcomponents#httpclient;4.1.2 compile

クリーン、リロード、手動更新の実行:

# sudo sbt
[info] Loading project definition from /Users/homedir/typesafe/my_app/project
[info] Set current project to my_app (in build file:/Users/homedir/typesafe/my_app/)
[my_app] $ clean
[success] Total time: 0 s, completed Aug 15, 2012 7:23:10 AM
[my_app] $ reload
[info] Loading project definition from /Users/homedir/typesafe/my_app/project
[info] Set current project to my_app (in build file:/Users/homedir/typesafe/my_app/)
[my_app] $ update
[info] Updating {file:/Users/homedir/typesafe/my_app/}my_app...
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::                                 
[warn]  ::          UNRESOLVED DEPENDENCIES         ::
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[warn]  :: org.slf4j#slf4j-api;1.6.1: configuration not found in org.slf4j#slf4j-api;1.6.1: 'compile'. It was required from org.hibernate#hibernate-validator;4.2.0.Final compile
[warn]  :: commons-codec#commons-codec;1.4: configuration not found in commons-codec#commons-codec;1.4: 'compile'. It was required from org.apache.httpcomponents#httpclient;4.1.2 compile
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[error] {file:/Users/homedir/typesafe/my_app/}my_app/:update: sbt.ResolveException: unresolved dependency: org.slf4j#slf4j-api;1.6.1: configuration not found in org.slf4j#slf4j-api;1.6.1: 'compile'. It was required from org.hibernate#hibernate-validator;4.2.0.Final compile
[error] unresolved dependency: commons-codec#commons-codec;1.4: configuration not found in commons-codec#commons-codec;1.4: 'compile'. It was required from org.apache.httpcomponents#httpclient;4.1.2 compile
[error] Total time: 7 s, completed Aug 15, 2012 7:23:23 AM

これを防ぐ適切な方法は何ですか?これらのdepsは初期化中にダウンロードされるべきではありませんか?

ありがとう!

4

2 に答える 2

2

この質問のおかげで、私は〜/ .m2と〜/ .ivy2を削除してから、クリーンアップ、更新、リロードを実行しました。その後、すべてがうまくいきました。updateコマンドはslf4jを正常に取得しました。

[my_app] $ update
[info] Updating {file:/Users/homedir/typesafe/my_app/}my_app...
[info] downloading http://repo.typesafe.com/typesafe/releases/org/slf4j/slf4j-api/1.6.1/slf4j-api-1.6.1.jar ...
[info]  [SUCCESSFUL ] org.slf4j#slf4j-api;1.6.1!slf4j-api.jar (1481ms)
于 2012-08-15T15:15:04.100 に答える
0

これを読むと、プッシュ/解決する前にタスクを実行することになります。

于 2013-09-17T20:05:52.860 に答える