为什么SBT找不到瓢虫?

时间:2016-05-18 14:15:30

标签: maven intellij-idea sbt findbugs

我有一个依赖Google findbugs的项目。当我从SBT控制台运行它时,我得到以下内容:

[info] Resolving com.google.code.findbugs#jsr305;1.3.+ ...
[warn]  module not found: com.google.code.findbugs#jsr305;1.3.+
[warn] ==== local: tried
[warn]   /Users/me/.ivy2/local/com.google.code.findbugs/jsr305/[revision]/ivys/ivy.xml
[warn] ==== public: tried
[warn]   https://repo1.maven.org/maven2/com/google/code/findbugs/jsr305/[revision]/jsr305-[revision].pom
[warn]   [3.0.1, 3.0.0, 2.0.3, 2.0.2]
[warn] ==== sbt-releases-repo: tried
[warn]   http://repo.typesafe.com/typesafe/ivy-releases/com.google.code.findbugs/jsr305/[revision]/ivys/ivy.xml
[warn] ==== sbt-plugins-repo: tried
[warn]   http://repo.scala-sbt.org/scalasbt/sbt-plugin-releases/com.google.code.findbugs/jsr305/[revision]/ivys/ivy.xml
[warn] ==== maven-central: tried
[warn]   http://repo1.maven.org/maven2/com/google/code/findbugs/jsr305/[revision]/jsr305-[revision].pom
[warn]   [3.0.1, 3.0.0, 2.0.3, 2.0.2]
[warn] ==== scalaz-bintray: tried
[warn] ==== Sonatype OSS Snapshots: tried
[warn]   http://oss.sonatype.org/content/repositories/snapshots/com/google/code/findbugs/jsr305/[revision]/jsr305-[revision].pom
[warn] ==== scalaz-bintray: tried
[warn]   http://dl.bintray.com/scalaz/releases/com/google/code/findbugs/jsr305/[revision]/jsr305-[revision].pom
[warn] ==== LocalIvy: tried
[warn] ==== Sonatype OSS Snapshots: tried
[warn]   http://oss.sonatype.org/content/repositories/snapshots/com/google/code/findbugs/jsr305/[revision]/jsr305-[revision].pom

然后,最后:

[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[warn]  ::          UNRESOLVED DEPENDENCIES         ::
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[warn]  :: com.google.code.findbugs#jsr305;1.3.+: not found
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[warn] 
[warn]  Note: Unresolved dependencies path:
[warn]      com.google.code.findbugs:jsr305:1.3.+

在Intellij的Libraries GUI中,我看到以下内容:

enter image description here

发生了什么?

1 个答案:

答案 0 :(得分:2)

您正在请求1.3.x,这是不可用的,3.0.x是可用的。更改您的构建以请求正确的版本