2017-01-24 11 views
0

sbtを使い始める。 私は、SBTの組み立て時にsbtアセンブリエラー重複排除

重複除外、このエラーを取得しています: ../.ivy2/cache/org.scalatest/scalatest_2.11/bundles/scalatest_2.11-2.2:以下で見つかった別のファイルの内容を。 6.jar:org/scalactic/SeqEqualityConstraints $ .class ../.ivy2/cache/org.scalactic/scalactic_2.11/bundles/scalactic_2.11-3.0.0.jar:org/scalactic/SeqEqualityConstraints$.class

これは私のビルドSBTです:

scalaVersion := "2.11.8" 
scalacOptions := Seq("-unchecked", "-feature", "-deprecation", "-encoding", "utf8") 

libraryDependencies ++= { 
    val phantomV   = "1.29.5" 
    val scalaTestV  = "2.2.6" 
    val scalaMockV  = "3.4.2" 
    val elastic4sV  = "2.4.0" 
    val akkaStreamVersion = "2.4.10" 
    val akkaVersion  = "2.3.12" 
    Seq(
    "com.websudos"   %% "phantom-dsl"      % phantomV, 
    "com.websudos"   %% "phantom-reactivestreams"   % phantomV, 
    "com.websudos"   %% "util-testing"      % "0.13.0" % "test, provided", 
    "com.typesafe.akka"  %% "akka-actor"       % akkaVersion, 
    "com.typesafe.akka"  %% "akka-http-spray-json-experimental" % akkaStreamVersion, 
    "com.typesafe.akka"  %% "akka-http-core"      % akkaStreamVersion, 
    "com.typesafe.akka"  %% "akka-http-experimental"    % akkaStreamVersion, 
    "com.typesafe.akka"  %% "akka-http-testkit"     % akkaStreamVersion, 
    "com.typesafe.akka"  %% "akka-stream"      % akkaStreamVersion, 
    "com.typesafe.akka"  %% "akka-stream-testkit"    % akkaStreamVersion, 
    "org.scalatest"   %% "scalatest"       % scalaTestV % "test, provided", 
    "com.typesafe.akka"  %% "akka-testkit"      % akkaVersion % "test, provided", 
    "com.typesafe.play"  %% "play-streams-experimental"   % "2.4.6"  % "provided", 
    "com.sksamuel.elastic4s" %% "elastic4s-core"      % elastic4sV, 
    "com.sksamuel.elastic4s" %% "elastic4s-streams"     % elastic4sV, 
    "org.scalamock"   %% "scalamock-scalatest-support"  % scalaMockV % "test, provided", 
    "com.typesafe"   % "config"        % "1.3.1" 

) 
} 
lazy val root = project.in(file(".")) 
    .settings(mainClass in assembly := Some("com.ind.Main")) 

initialCommands := """|import akka.actor._ 
         |import akka.pattern._ 
         |import akka.util._ 
         |import scala.concurrent._ 
         |import scala.concurrent.duration._""".stripMargin 

fork in run := true 
test in assembly := {} 

なぜそれを取得し、どのように私はそれを解決することができます任意のアイデア?

===== UPDATE ==== 私はScalaTestとScalacticバージョン番号が一致する必要が

assemblyMergeStrategy in assembly := { 
    case PathList("META-INF", xs @ _*) => MergeStrategy.discard 
    case x => MergeStrategy.first 
} 
+0

解決策を回答として投稿することをお勧めします。その結果、最終的に質問を閉じることができます –

答えて

0
assemblyMergeStrategy in assembly := { 
    case PathList("META-INF", xs @ _*) => MergeStrategy.discard 
    case x => MergeStrategy.first 
} 
0

を追加することによって、それを解決するために管理しました。あなたはScalaTest 2.2.6でScalactic 3.0.0を使用しようとしているので、それが問題です。あなたの依存関係の1つはScalactic 3.0.0を使用している可能性があります。

関連する問題