3

我在我的 Mac (El Capitan) 上安装了 spark 1.6.0、java 1.8.0_73 和 sbt 0.13.9

当我键入时,sbt assembly我收到以下错误。

[error] (sql/compile:compile) java.lang.AssertionError: assertion failed: List(object package$DebugNode, object package$DebugNode)
[error] (hive/*:update) java.lang.IllegalStateException: impossible to get artifacts when data has not been loaded. IvyNode = org.scala-lang#scala-library;2.10.3
[error] Total time: 108 s, completed Feb 15, 2016 3:47:40 PM

我调查了这个错误,似乎依赖列表与它有关。有谁知道如何解决这个问题?具体来说,我需要编辑 sbt 依赖列表吗?如果是这样,它将是哪个文件,我应该如何编辑它?

根据尤金的要求,我包括以下文件。如果我得到了错误的构建文件,请耐心等待(我是新来的),让我知道我应该发布哪些文件。感谢您的帮助!

构建.sbt

name := "sbt-pom-reader"

organization := "com.typesafe.sbt"

sbtPlugin := true

publishMavenStyle := false

libraryDependencies ++= Dependencies.pluginDependencies

git.baseVersion := "1.0"

versionWithGit

scriptedLaunchOpts <+= version apply { v => "-Dproject.version="+v }

initialCommands :=
  """| import com.typesafe.sbt.pom._
     | import sbt._
     | val localRepo = file(sys.props("user.home")) / ".m2" / "repository"
     | val pom = loadEffectivePom(localRepo, file("src/sbt-test/simple-pom/can-extract-basics/pom.xml"))
     |""".stripMargin


scriptedSettings

scriptedLaunchOpts <+= version apply { v => "-Dproject.version="+v }

publishTo <<= (version) { v =>
  def scalasbt(repo: String) = ("scalasbt " + repo, "http://scalasbt.artifactoryonline.com/scalasbt/sbt-plugin-" + repo)
  val (name, repo) = if (v.endsWith("-SNAPSHOT")) scalasbt("snapshots") else scalasbt("releases")
  Some(Resolver.url(name, url(repo))(Resolver.ivyStylePatterns))
}
4

0 回答 0