如何解决新SBT安装中的常春藤配置问题
安装了新的笔记本电脑全新的sbt。当我show resolvers
正常URL时,这就是我期望的一切,而当运行show fullResolvers
时,它会重现错误。这是sbt 1.3.13,但我尝试了其他1.3版和0.13版,结果相似。我能够使用mill构建一个不同的应用程序,因此我认为这与基础的Java安装无关。
[error] java.lang.IllegalArgumentException: invalid host wildcard specification
[error] at java.net.socketPermission.init(SocketPermission.java:447)
[error] at java.net.socketPermission.<init>(SocketPermission.java:291)
[error] at java.lang.SecurityManager.checkConnect(SecurityManager.java:1048)
[error] at java.net.InetAddress.getLocalHost(InetAddress.java:1478)
[error] at org.apache.ivy.util.HostUtil.getLocalHostName(HostUtil.java:46)
[error] at org.apache.ivy.plugins.resolver.BasicResolver.<init>(BasicResolver.java:156)
[error] at org.apache.ivy.plugins.resolver.AbstractPatternsBasedResolver.<init>(AbstractPatternsBasedResolver.java:58)
[error] at org.apache.ivy.plugins.resolver.RepositoryResolver.<init>(RepositoryResolver.java:65)
[error] at org.apache.ivy.plugins.resolver.URLResolver.<init>(URLResolver.java:27)
[error] at org.apache.ivy.plugins.resolver.IBiblioResolver.<init>(IBiblioResolver.java:83)
[error] at sbt.internal.librarymanagement.ConvertResolver$$anonfun$defaultConvert$lzycompute$1$PluginCapableResolver$1.<init>(ConvertResolver.scala:166)
[error] at sbt.internal.librarymanagement.ConvertResolver$$anonfun$defaultConvert$lzycompute$1.applyOrElse(ConvertResolver.scala:177)
[error] at sbt.internal.librarymanagement.ConvertResolver$$anonfun$defaultConvert$lzycompute$1.applyOrElse(ConvertResolver.scala:154)
[error] at scala.runtime.AbstractPartialFunction.apply(AbstractPartialFunction.scala:38)
[error] at sbt.internal.librarymanagement.ConvertResolver$.apply(ConvertResolver.scala:151)
[error] at sbt.internal.librarymanagement.IvySbt$.$anonfun$resolverChain$1(Ivy.scala:517)
[error] at scala.collection.TraversableLike.$anonfun$map$1(TraversableLike.scala:238)
[error] at scala.collection.Iterator.foreach(Iterator.scala:941)
[error] at scala.collection.Iterator.foreach$(Iterator.scala:941)
[error] at scala.collection.AbstractIterator.foreach(Iterator.scala:1429)
[error] at scala.collection.IterableLike.foreach(IterableLike.scala:74)
[error] at scala.collection.IterableLike.foreach$(IterableLike.scala:73)
[error] at scala.collection.AbstractIterable.foreach(Iterable.scala:56)
[error] at scala.collection.TraversableLike.map(TraversableLike.scala:238)
[error] at scala.collection.TraversableLike.map$(TraversableLike.scala:231)
[error] at scala.collection.AbstractTraversable.map(Traversable.scala:108)
[error] at sbt.internal.librarymanagement.IvySbt$.resolverChain(Ivy.scala:517)
[error] at sbt.internal.librarymanagement.IvySbt$.makeChain$1(Ivy.scala:486)
[error] at sbt.internal.librarymanagement.IvySbt$.sbt$internal$librarymanagement$IvySbt$$setResolvers(Ivy.scala:490)
[error] at sbt.internal.librarymanagement.IvySbt.settings$lzycompute(Ivy.scala:138)
[error] at sbt.internal.librarymanagement.IvySbt.sbt$internal$librarymanagement$IvySbt$$settings(Ivy.scala:95)
[error] at sbt.internal.librarymanagement.IvySbt.ivyLockFile$lzycompute(Ivy.scala:200)
[error] at sbt.internal.librarymanagement.IvySbt.ivyLockFile(Ivy.scala:200)
[error] at sbt.internal.librarymanagement.IvySbt.withDefaultLogger(Ivy.scala:87)
[error] at sbt.internal.librarymanagement.IvySbt.withIvy(Ivy.scala:209)
[error] at sbt.internal.librarymanagement.IvySbt.withIvy(Ivy.scala:206)
[error] at sbt.internal.librarymanagement.IvySbt$Module.withModule(Ivy.scala:250)
[error] at sbt.internal.librarymanagement.IvySbt$Module.moduleDescriptor(Ivy.scala:254)
[error] at sbt.internal.librarymanagement.IvySbt$Module.dependencyMapping(Ivy.scala:256)
[error] at sbt.Classpaths$.$anonfun$depMap$5(Defaults.scala:3111)
[error] at scala.collection.TraversableLike.$anonfun$map$1(TraversableLike.scala:238)
[error] at scala.collection.immutable.List.foreach(List.scala:392)
[error] at scala.collection.TraversableLike.map(TraversableLike.scala:238)
[error] at scala.collection.TraversableLike.map$(TraversableLike.scala:231)
[error] at scala.collection.immutable.List.map(List.scala:298)
[error] at sbt.Classpaths$.$anonfun$depMap$4(Defaults.scala:3111)
[error] at scala.Function1.$anonfun$compose$1(Function1.scala:49)
[error] at sbt.internal.util.$tilde$greater.$anonfun$$u2219$1(TypeFunctions.scala:62)
[error] at sbt.std.Transform$$anon$4.work(Transform.scala:67)
[error] at sbt.Execute.$anonfun$submit$2(Execute.scala:281)
[error] at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:19)
[error] at sbt.Execute.work(Execute.scala:290)
[error] at sbt.Execute.$anonfun$submit$1(Execute.scala:281)
[error] at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:178)
[error] at sbt.CompletionService$$anon$2.call(CompletionService.scala:37)
[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)
编辑:并非每个项目都会导致问题,只是那些具有项目依赖项的多项目版本会导致问题。 最小复制build.sbt文件
name := "untitled"
version := "0.1"
scalaVersion := "2.13.3"
lazy val projectA = project
lazy val projectB = project.dependsOn(projectA)
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。