이창언
이창언

Reputation: 1

why is trouble that Spark issue at sbt in intellij

name := "name"

version := "1.0"

scalaVersion := "2.11.7"

libraryDependencies += "org.apache.spark" %% "spark-core" % "2.0.2"

Log:

[warn] Multiple dependencies with the same organization/name but different versions.
To avoid conflict, pick one version:
[warn]  * org.scala-lang:scala-compiler:(2.11.0, 2.11.7)
[warn]  * org.scala-lang:scala-library:(2.11.8, 2.11.7)
[warn]  * org.scala-lang.modules:scala-parser-combinators_2.11:(1.0.1, 1.0.4)
[warn]  * org.scala-lang.modules:scala-xml_2.11:(1.0.2, 1.0.4)

Upvotes: 0

Views: 72

Answers (1)

FaigB
FaigB

Reputation: 2281

You can exclude the unwanted versions of dependencies by checking dependency tree

or

In dedicated way telling sbt to choose one you want like:

libraryDependencies ++= Seq(   
   "org.scala-lang" % "scala-compiler" % "2.11.7",   
   "org.scala-lang.modules" % "scala-parser-combinators_2.11" % "1.0.4",
   "org.scala-lang" % "scala-library" % "2.11.7",   
   "org.scala-lang.modules" % "scala-xml_2.11" % "1.0.4" 
)

Upvotes: 1

Related Questions