Error while importing sbt project:--创建sbt项目导入文件出错
错误截图如下:
Error while importing sbt project: List([info] Loading global plugins from C:\Users\RYJ\.sbt\1.0\plugins
[warn] insecure HTTP request is deprecated 'http://maven.aliyun.com/nexus/content/groups/public'; switch to HTTPS or opt-in as ("aliyun" at "http://maven.aliyun.com/nexus/content/groups/public").withAllowInsecureProtocol(true)
[warn] insecure HTTP request is deprecated 'http://maven.aliyun.com/nexus/content/groups/public'; switch to HTTPS or opt-in as ("aliyun" at "http://maven.aliyun.com/nexus/content/groups/public").withAllowInsecureProtocol(true)
[warn] insecure HTTP request is deprecated 'http://maven.aliyun.com/nexus/content/groups/public'; switch to HTTPS or opt-in as ("aliyun" at "http://maven.aliyun.com/nexus/content/groups/public").withAllowInsecureProtocol(true)
[warn] insecure HTTP request is deprecated 'Patterns(ivyPatterns=Vector(http://repo.typesafe.com/typesafe/ivy-releases/[organization]/[module]/[revision]/[type]s/[artifact](-[classifier]).[ext]), artifactPatterns=Vector(http://repo.typesafe.com/typesafe/ivy-releases/[organization]/[module]/[revision]/[type]s/[artifact](-[classifier]).[ext]), isMavenCompatible=false, descriptorOptional=false, skipConsistencyCheck=false)'; switch to HTTPS or opt-in as Resolver.url("typesafe-ivy-releases", url(...)).withAllowInsecureProtocol(true)
[info] Loading project definition from F:\Code\Java\SbtObj\project
[warn] insecure HTTP request is deprecated 'http://maven.aliyun.com/nexus/content/groups/public'; switch to HTTPS or opt-in as ("aliyun" at "http://maven.aliyun.com/nexus/content/groups/public").withAllowInsecureProtocol(true)
[warn] insecure HTTP request is deprecated 'http://maven.aliyun.com/nexus/content/groups/public'; switch to HTTPS or opt-in as ("aliyun" at "http://maven.aliyun.com/nexus/content/groups/public").withAllowInsecureProtocol(true)
[warn] insecure HTTP request is deprecated 'Patterns(ivyPatterns=Vector(http://repo.typesafe.com/typesafe/ivy-releases/[organization]/[module]/[revision]/[type]s/[artifact](-[classifier]).[ext]), artifactPatterns=Vector(http://repo.typesafe.com/typesafe/ivy-releases/[organization]/[module]/[revision]/[type]s/[artifact](-[classifier]).[ext]), isMavenCompatible=false, descriptorOptional=false, skipConsistencyCheck=false)'; switch to HTTPS or opt-in as Resolver.url("typesafe-ivy-releases", url(...)).withAllowInsecureProtocol(true)
[warn] insecure HTTP request is deprecated 'http://maven.aliyun.com/nexus/content/groups/public'; switch to HTTPS or opt-in as ("aliyun" at "http://maven.aliyun.com/nexus/content/groups/public").withAllowInsecureProtocol(true)
[info] Loading settings for project sbtobj from build.sbt ...
[info] Set current project to SbtObj (in build file:/F:/Code/Java/SbtObj/)
[info] sbt server started at local:sbt-server-74de12ff202df04b48d5
sbt:SbtObj>
[info] Defining Global / sbtStructureOptions, Global / sbtStructureOutputFile and others.
[info] The new values will be used by cleanKeepGlobs
[info] Run `last` for details.
[info] Reapplying settings...
[info] Set current project to SbtObj (in build file:/F:/Code/Java/SbtObj/)
[info] Applying State transformations org.jetbrains.sbt.CreateTasks from C:/Users/RYJ/.IntelliJIdea2019./config/plugins/Scala/repo/org.jetbrains/sbt-structure-extractor/scala_2./sbt_1./2018.2.+-88400d3f/jars/sbt-structure-extractor.jar
[info] Reapplying settings...
[info] Set current project to SbtObj (in build file:/F:/Code/Java/SbtObj/)
[warn] insecure HTTP request is deprecated 'http://maven.aliyun.com/nexus/content/groups/public'; switch to HTTPS or opt-in as ("aliyun" at "http://maven.aliyun.com/nexus/content/groups/public").withAllowInsecureProtocol(true)
[warn] insecure HTTP request is deprecated 'http://maven.aliyun.com/nexus/content/groups/public'; switch to HTTPS or opt-in as ("aliyun" at "http://maven.aliyun.com/nexus/content/groups/public").withAllowInsecureProtocol(true)
[error] stack trace is suppressed; run 'last update' for the full output
[error] stack trace is suppressed; run 'last ssExtractDependencies' for the full output
[error] (update) lmcoursier.internal.shaded.coursier.error.FetchError$DownloadingArtifacts: Error fetching artifacts:
[error] https://repo1.maven.org/maven2/org/scala-lang/scala-compiler/2.13.1/scala-compiler-2.13.1.jar: wrong checksum: C:\Users\RYJ\AppData\Local\Coursier\cache\v1\https\repo1.maven.org\maven2\org\scala-lang\scala-compiler\2.13.1\scala-compiler-2.13.1.jar (expected SHA-1 2669fd1abfe2c76de9201174255f8454aa25c3e2 in C:\Users\RYJ\AppData\Local\Coursier\cache\v1\https\repo1.maven.org\maven2\org\scala-lang\scala-compiler\2.13.1\.scala-compiler-2.13.1.jar__sha1, got 1b073ccae686e76f296677dea625a1abd7e0eaac)
[error] (ssExtractDependencies) lmcoursier.internal.shaded.coursier.error.FetchError$DownloadingArtifacts: Error fetching artifacts:
[error] https://repo1.maven.org/maven2/org/scala-lang/scala-compiler/2.13.1/scala-compiler-2.13.1.jar: wrong checksum: C:\Users\RYJ\AppData\Local\Coursier\cache\v1\https\repo1.maven.org\maven2\org\scala-lang\scala-compiler\2.13.1\scala-compiler-2.13.1.jar (expected SHA-1 2669fd1abfe2c76de9201174255f8454aa25c3e2 in C:\Users\RYJ\AppData\Local\Coursier\cache\v1\https\repo1.maven.org\maven2\org\scala-lang\scala-compiler\2.13.1\.scala-compiler-2.13.1.jar__sha1, got 1b073ccae686e76f296677dea625a1abd7e0eaac)
[error] Total time: s, completed -- ::
[info] shutting down sbt server)
解决方案:
1.更换镜像为国内
由于墙的问题,需要把下载源改为国内镜像,上面截图是我改过的,如果你改过也不行,直接看解决方案2.。
在.sbt项目下 (.sbt项目可以在文件管理器中直接搜索,默认是在C:\Users\用户名\.sbt 下) 面创建repositories文件(注意不需要任何后缀),然后添加如下内容:
[repositories]
local
aliyun: http://maven.aliyun.com/nexus/content/groups/public
typesafe-ivy-releases: http://repo.typesafe.com/typesafe/ivy-releases/, [organization]/[module]/[revision]/[type]s/[artifact](-[classifier]).[ext], bootOnly
sonatype-oss-releases
maven-central
sonatype-oss-snapshots
其它不用动,重新右键Reimport sbt Project运行看看,可以看到镜像已经从阿里云下载了。 当然了,这步设置好可能还是报错,没事,看第二个解决方案。
2.降低软件包版本
上面还是报错很大原因推测是下载的文件不存在或者找不到导致的,有可能你安装的这个文件太新了,国内镜像库还没同步过来,国外又访问不了,所以降低版本就行了。
修改项目中的build.sbt文件,这里我因为是scala报错了,所以将 scalaVersion := "2.13.1" 改为 scalaVersion := "2.12.10", 然后保存,发现已经可以了。
Error while importing sbt project:--创建sbt项目导入文件出错的更多相关文章
- [转]ADT中通过DDMS导入文件出错ddms transfer error: Read-only file system,Failed to push selection: Read-only file system
[已解决] 原文 http://www.crifan.com/ddms_import_file_error_transfer_error_read_only_file_system/ 想要通过adt ...
- 命令行创建Maven项目卡住以及出错解决办法。
第一次通过命令行创建maven项目.结果,果不其然啊,还是出问题了,不过出问题比没有出问题强,知道哪里有问题并学会解决也是一种收获. 遇到的第一个问题,在从仓库下载东西的时候会卡住,我开始以为是网速问 ...
- MyEclipse下创建的项目导入到Eclipse中详细的图文配置方法
一.情景再现. 有些人比较喜欢用Myeclipse开发,有些人却比较喜欢用eclipse开发.但是其中有一个问题,Myeclipse里面的项目导入的时候出现了一个小小的问题. 如下: 二.说明问题 导 ...
- MyEclipse下创建的项目 导入eclipse
1.导入在MyEclipse下创建的项目 2.把项目变成Web项目,在项目上右键-->Properties-->选择Project Facets-->点击Convert to fac ...
- Eclipse和MyEclipse使用技巧--MyEclipse下创建的项目导入到Eclipse中详细的图文配置方法
一.情景再现. 有些人比较喜欢用Myeclipse开发,有些人却比较喜欢用eclipse开发.但是其中有一个问题,Myeclipse里面的项目导入的时候出现了一个小小的问题. 如下: 二.说明问题 导 ...
- 【maven】maven创建web项目-pom文件提示web.xml is missing and <failOnMissingWebXml> is set to true
使用maven创建web项目,选择war类型后,pom文件红叉 提示web.xml is missing and <failOnMissingWebXml> is set to true ...
- javaweb项目导入myecplise出错
项目导入出错:移动项目的时候.classpath .project不要删 build path -> use for source floder 把某一文件夹当作源码文件夹 bulid path ...
- vs 2019 create new project 创建新项目
下面的place solution and project in the same directory 不需要勾选
- mvn 创建的项目 导入到eclipse
首先,我的工具版本如下: jdk: java version "1.6.0_10-rc2"; maven: apache-maven-3.1.0; eclipse: MyEclip ...
随机推荐
- Kubernetes详解
1.1 Kubernetes简介 1.1.1 什么是Kubernetes Kubernetes (通常称为K8s,K8s是将8个字母“ubernete”替换为“8”的缩写) 是一个以容器为中心的基础架 ...
- JavaScript深入浅出-闭包
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 function (){ var localVal ...
- mysql视图、事务、触发器、索引
视图 什么是视图 ? 一个查询语句的结果是一张虚拟表,将这种虚拟表保存下来,它就变成了一个视图. 为什么要用视图? 当频繁需要用到多张表的连表结果,你就可以事先生成好视图,之后直接调用即可,避免了反复 ...
- mysql启动报错ERROR! The server quit without updating PID file处理
从其它服务器拷贝编译安装后的MySQL5.7目录后启动时报错如下: ERROR! The server quit without updating PID file(/path/to/XXX.pid) ...
- 致敬——C语言
2016年4月26日21:00 OJ考试平台关闭,C语言这门课程也就随之结束了. 回顾学习历程,坦诚的讲学习期间也努力过也颓废过,但从来没有绝对的放弃过.由于种种客观原因与主观原因导致没有给 ...
- AI入门之KNN算法学习
一.什么是KNN算法 kNN(k-NearestNeighbor),也就是k最近邻算法.顾名思义,所谓K最近邻,就是k个最近的邻居的意思.也就是在数据集中,认为每个样本可以用离他最距离近的k个邻居来代 ...
- java基础进阶篇(二)_Arraylist ------【java源码栈】
前言 ArrayList 在开发中用到的频率很高,其中原生态提供的方法有一些很好用的重载版本,其中有的坑该跳得跳啊. 一.ArrayList的6种初始化方法1.构造方法 参数为空2.构造方法 参数为L ...
- 图解Python网络编程
返回目录 本篇索引 (1)基本原理 (2)socket模块 (3)select模块 (4)asyncore模块 (5)asynchat模块 (6)socketserver模块 (1)基本原理 本篇指的 ...
- Java面试必问之Hashmap底层实现原理(JDK1.7)
1. 前言 Hashmap可以说是Java面试必问的,一般的面试题会问: Hashmap有哪些特性? Hashmap底层实现原理(get\put\resize) Hashmap怎么解决hash冲突? ...
- JZOJ 5328. 【NOIP2017提高A组模拟8.22】世界线
5328. [NOIP2017提高A组模拟8.22]世界线 (File IO): input:worldline.in output:worldline.out Time Limits: 1500 m ...