当前位置: 首页 > 知识库问答 >
问题:

将scala play项目导入Intellij时出错

邴墨竹
2023-03-14
sbt new playframework/play-scala-seed.g8
Error while importing sbt project:

[info] Loading settings from plugins.sbt,scaffold.sbt ...
[info] Loading project definition from /home/x/IdeaProjects/p3/u/project
[info] Loading settings from build.sbt ...
[info] Set current project to user (in build file:/home/x/IdeaProjects/p3/u/)
[info] sbt server started at 127.0.0.1:4315
[user] $
[info] Defining */*:sbtStructureOptions, */*:sbtStructureOutputFile, *:shellPrompt
[info] The new values will be used by no settings or tasks.
[info] Reapplying settings...
[info] Set current project to user (in build file:/home/x/IdeaProjects/p3/u/)
[info] Applying State transformations org.jetbrains.sbt.CreateTasks from /home/x/.IdeaIC2017.3/config/plugins/Scala/launcher/sbt-structure-1.0.jar
[info] Reapplying settings...
[info] Set current project to user (in build file:/home/x/IdeaProjects/p3/user/)
[warn]  Detected merged artifact: [FAILED     ] com.typesafe.sbt#sbt-native-packager;1.3.2!sbt-native-packager.jar(src):  (0ms).
[warn]  Detected merged artifact: [FAILED     ] com.typesafe.sbt#sbt-web;1.4.3!sbt-web.jar(doc):  (0ms).
[warn] ==== local: tried
[warn] ==== local: tried
[warn]   /home/x/.ivy2/local/com.typesafe.sbt/sbt-web/scala_2.12/sbt_1.0/1.4.3/docs/sbt-web-javadoc.jar
[warn]   /home/x/.ivy2/local/com.typesafe.sbt/sbt-native-packager/scala_2.12/sbt_1.0/1.3.2/srcs/sbt-native-packager-sources.jar
[warn] ==== public: tried
[warn] ==== public: tried
[warn]   https://repo1.maven.org/maven2/com/typesafe/sbt/sbt-web_2.12_1.0/1.4.3/sbt-web-1.4.3-javadoc.jar
[warn]   https://repo1.maven.org/maven2/com/typesafe/sbt/sbt-native-packager_2.12_1.0/1.3.2/sbt-native-packager-1.3.2-sources.jar
[warn] ==== local-preloaded-ivy: tried
[warn] ==== local-preloaded-ivy: tried
[warn]   /home/x/.sbt/preloaded/com.typesafe.sbt/sbt-web/1.4.3/docs/sbt-web-javadoc.jar
[warn]   /home/x/.sbt/preloaded/com.typesafe.sbt/sbt-native-packager/1.3.2/srcs/sbt-native-packager-sources.jar
[warn] ==== local-preloaded: tried
[warn] ==== local-preloaded: tried
[warn]   file:////home/x/.sbt/preloaded/com/typesafe/sbt/sbt-web_2.12_1.0/1.4.3/sbt-web-1.4.3-javadoc.jar
[warn]   file:////home/x/.sbt/preloaded/com/typesafe/sbt/sbt-native-packager_2.12_1.0/1.3.2/sbt-native-packager-1.3.2-sources.jar
[warn]  Detected merged artifact: [FAILED     ] com.typesafe.sbt#sbt-web;1.4.3!sbt-web.jar(src):  (0ms).
[warn]  Detected merged artifact: [FAILED     ] com.typesafe.sbt#sbt-native-packager;1.3.2!sbt-native-packager.jar(doc):  (0ms).
[warn] ==== local: tried
[warn] ==== local: tried
[warn]   /home/x/.ivy2/local/com.typesafe.sbt/sbt-web/scala_2.12/sbt_1.0/1.4.3/srcs/sbt-web-sources.jar
[warn] ==== public: tried
[warn]   /home/x/.ivy2/local/com.typesafe.sbt/sbt-native-packager/scala_2.12/sbt_1.0/1.3.2/docs/sbt-native-packager-javadoc.jar
[warn]   https://repo1.maven.org/maven2/com/typesafe/sbt/sbt-web_2.12_1.0/1.4.3/sbt-web-1.4.3-sources.jar
[warn] ==== public: tried
[warn] ==== local-preloaded-ivy: tried
[warn]   https://repo1.maven.org/maven2/com/typesafe/sbt/sbt-native-packager_2.12_1.0/1.3.2/sbt-native-packager-1.3.2-javadoc.jar
[warn]   /home/x/.sbt/preloaded/com.typesafe.sbt/sbt-web/1.4.3/srcs/sbt-web-sources.jar
[warn] ==== local-preloaded-ivy: tried
[warn] ==== local-preloaded: tried
[warn]   /home/x/.sbt/preloaded/com.typesafe.sbt/sbt-native-packager/1.3.2/docs/sbt-native-packager-javadoc.jar
[warn]   file:////home/x/.sbt/preloaded/com/typesafe/sbt/sbt-web_2.12_1.0/1.4.3/sbt-web-1.4.3-sources.jar
[warn] ==== local-preloaded: tried
[warn]   file:////home/x/.sbt/preloaded/com/typesafe/sbt/sbt-native-packager_2.12_1.0/1.3.2/sbt-native-packager-1.3.2-javadoc.jar
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[warn]  ::              FAILED DOWNLOADS            ::
[warn]  :: ^ see resolution messages for details  ^ ::
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[warn]  :: com.typesafe.sbt#sbt-native-packager;1.3.2!sbt-native-packager.jar(src)
[warn]  :: com.typesafe.sbt#sbt-native-packager;1.3.2!sbt-native-packager.jar(doc)
[warn]  :: com.typesafe.sbt#sbt-web;1.4.3!sbt-web.jar(doc)
[warn]  :: com.typesafe.sbt#sbt-web;1.4.3!sbt-web.jar(src)
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[error] sbt.librarymanagement.ResolveException: download failed: com.typesafe.sbt#sbt-native-packager;1.3.2!sbt-native-packager.jar(src)
[error] download failed: com.typesafe.sbt#sbt-native-packager;1.3.2!sbt-native-packager.jar(doc)
[error] download failed: com.typesafe.sbt#sbt-web;1.4.3!sbt-web.jar(doc)
[error] download failed: com.typesafe.sbt#sbt-web;1.4.3!sbt-web.jar(src)
[error]     at sbt.internal.librarymanagement.IvyActions$.resolveAndRetrieve(IvyActions.scala:331)
[error]     at sbt.internal.librarymanagement.IvyActions$.$anonfun$updateEither$1(IvyActions.scala:205)
[error]     at sbt.internal.librarymanagement.IvySbt$Module.$anonfun$withModule$1(Ivy.scala:243)
[error]     at sbt.internal.librarymanagement.IvySbt.$anonfun$withIvy$1(Ivy.scala:204)
[error]     at sbt.internal.librarymanagement.IvySbt.sbt$internal$librarymanagement$IvySbt$$action$1(Ivy.scala:70)
[error]     at sbt.internal.librarymanagement.IvySbt$$anon$3.call(Ivy.scala:77)
[error]     at xsbt.boot.Locks$GlobalLock.withChannel$1(Locks.scala:93)
[error]     at xsbt.boot.Locks$GlobalLock.xsbt$boot$Locks$GlobalLock$$withChannelRetries$1(Locks.scala:78)
[error]     at xsbt.boot.Locks$GlobalLock$$anonfun$withFileLock$1.apply(Locks.scala:97)
[error]     at xsbt.boot.Using$.withResource(Using.scala:10)
[error]     at xsbt.boot.Using$.apply(Using.scala:9)
[error]     at xsbt.boot.Locks$GlobalLock.ignoringDeadlockAvoided(Locks.scala:58)
[error]     at xsbt.boot.Locks$GlobalLock.withLock(Locks.scala:48)
[error]     at xsbt.boot.Locks$.apply0(Locks.scala:31)
[error]     at xsbt.boot.Locks$.apply(Locks.scala:28)
[error]     at sbt.internal.librarymanagement.IvySbt.withDefaultLogger(Ivy.scala:77)
[error]     at sbt.internal.librarymanagement.IvySbt.withIvy(Ivy.scala:199)
[error]     at sbt.internal.librarymanagement.IvySbt.withIvy(Ivy.scala:196)
[error]     at sbt.internal.librarymanagement.IvySbt$Module.withModule(Ivy.scala:242)
[error]     at sbt.internal.librarymanagement.IvyActions$.updateEither(IvyActions.scala:190)
[error]     at sbt.librarymanagement.ivy.IvyDependencyResolution.update(IvyDependencyResolution.scala:20)
[error]     at sbt.librarymanagement.DependencyResolution.update(DependencyResolution.scala:56)
[error]     at sbt.internal.LibraryManagement$.transitiveScratch(LibraryManagement.scala:135)
[error]     at sbt.Classpaths$.$anonfun$sbtClassifiersTasks$12(Defaults.scala:2178)
[error]     at sbt.Classpaths$$anon$4.call(Defaults.scala:2256)
[error]     at sbt.Classpaths$$anon$4.call(Defaults.scala:2249)
[error]     at xsbt.boot.Locks$GlobalLock.withChannel$1(Locks.scala:93)
[error]     at xsbt.boot.Locks$GlobalLock.xsbt$boot$Locks$GlobalLock$$withChannelRetries$1(Locks.scala:78)
[error]     at xsbt.boot.Locks$GlobalLock$$anonfun$withFileLock$1.apply(Locks.scala:97)
[error]     at xsbt.boot.Using$.withResource(Using.scala:10)
[error]     at xsbt.boot.Using$.apply(Using.scala:9)
[error]     at xsbt.boot.Locks$GlobalLock.ignoringDeadlockAvoided(Locks.scala:58)
[error]     at xsbt.boot.Locks$GlobalLock.withLock(Locks.scala:48)
[error]     at xsbt.boot.Locks$.apply0(Locks.scala:31)
[error]     at xsbt.boot.Locks$.apply(Locks.scala:28)
[error]     at sbt.Classpaths$.withExcludes(Defaults.scala:2249)
[error]     at sbt.Classpaths$.$anonfun$sbtClassifiersTasks$10(Defaults.scala:2165)
[error]     at scala.Function1.$anonfun$compose$1(Function1.scala:44)
[error]     at sbt.internal.util.$tilde$greater.$anonfun$$u2219$1(TypeFunctions.scala:42)
[error]     at sbt.std.Transform$$anon$4.work(System.scala:64)
[error]     at sbt.Execute.$anonfun$submit$2(Execute.scala:257)
[error]     at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:16)
[error]     at sbt.Execute.work(Execute.scala:266)
[error]     at sbt.Execute.$anonfun$submit$1(Execute.scala:257)
[error]     at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:167)
[error]     at sbt.CompletionService$$anon$2.call(CompletionService.scala:32)
[error]     at java.util.concurrent.FutureTask.run(FutureTask.java:266)

[error]     at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[error]     at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error]     at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[error]     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[error]     at java.lang.Thread.run(Thread.java:748)
[error] (*:updateSbtClassifiers) sbt.librarymanagement.ResolveException: download failed: com.typesafe.sbt#sbt-native-packager;1.3.2!sbt-native-packager.jar(src)
[error] download failed: com.typesafe.sbt#sbt-native-packager;1.3.2!sbt-native-packager.jar(doc)
[error] download failed: com.typesafe.sbt#sbt-web;1.4.3!sbt-web.jar(doc)
[error] download failed: com.typesafe.sbt#sbt-web;1.4.3!sbt-web.jar(src)
[error] Total time: 8 s, completed 26-Jan-2018 22:39:24
[INFO] [01/26/2018 22:39:24.162] [Thread-4] [CoordinatedShutdown(akka://sbt-web)] Starting coordinated shutdown from JVM shutdown hook

有什么想法可以解决这个问题吗?在Arch Linux上使用这个版本的Intellij

IntelliJ IDEA社区版(Intellij-IDEA-Communition-Edition)2:2017.3.3-1

共有1个答案

欧阳飞
2023-03-14

添加了这个,现在可以工作了:

resolvers += Resolver.sbtPluginRepo("releases")

根据这些说明:

https://github.com/sbt/sbt-native-packager/pull/1066

 类似资料:
  • 是否有办法将GradleJava项目导入IntelliJ 2017.2. x并应用一些设置,例如 代码样式 vcs设置 从Gradle在项目层面? 我注意到例如Grails框架使用了idea-gradle-plugin,但这只能与Gradle任务结合使用。 我不想使用Gradle任务生成IntelliJ项目文件。每当我导入文件。 这可能吗?

  • 知道为什么会这样吗?我的同事可以毫无问题地将项目导入他们的IntelliJ。 单击不执行任何操作。 系统: null

  • 下面是我在构建SBT项目时看到的日志。下面想说的是什么! 我正在使用IntelliJ IDE和Scala2.12以及SBT1.0.3来构建这个项目。我已经验证了IDE代理设置,它的设置和工作良好的其他构建工具。是否有什么东西错过了我的SBT安装??我尝试访问日志中的失败链接,它们也出现了错误。 更新:以下是文件内容 build.sbt 名称:=“unttled3” 版本:=“0.1” scalaV

  • 我想将我的Eclipse项目导入IntelliJ IDEA,所以我转到了IntelliJ IDEA帮助页面: 如果IntelliJ IDEA中当前没有打开的项目,请单击欢迎屏幕上的导入项目。否则,选择文件|导入项目。 问题是欢迎屏幕上没有导入项目选项,文件菜单中也没有导入项目选项。 有什么办法吗? 我查看了更新,它告诉我我的11.1.3版本是最新的,尽管帮助页面的标题栏中有12.0。

  • 我已将IntelliJ从CE 2017.2升级到CE 2017.3版。5,现在我无法构建我的sbt项目。构建在第一步就被卡住了: 我已经删除了。idea目录和目录。我从命令行生成了一个sbt,这很有效。然后我再次启动IntelliJ并尝试导入作为一个项目。我也已注销/登录。这样做了好几次。导入过程永远不会超过此步骤。 我在防火墙后面工作,但是我已经检查了我的代理设置,它们是正确的,并且与以前的版本