Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fails with NoClassDefFoundError on Sbt 1.1.5 #3

Open
dragos opened this issue Nov 23, 2018 · 1 comment
Open

Fails with NoClassDefFoundError on Sbt 1.1.5 #3

dragos opened this issue Nov 23, 2018 · 1 comment

Comments

@dragos
Copy link

dragos commented Nov 23, 2018

I am really excited about this, as it seems to speed up Sbt considerably. However, I tried it on two projects and failed with different errors:

for Sbt 1.1.5:

[info] Fetched artifacts of hydra-build
[info] Compiling 3 Scala sources to /Users/dragos/workspace/triplequote/hydra/project/target/scala-2.12/sbt-1.0/classes ...
[info] Non-compiled module 'compiler-bridge_2.12' for Scala 2.12.7. Compiling...
[info]   Compilation completed in 8.71s.
[info] Done compiling.
[error] java.lang.NoClassDefFoundError: org/vafer/jdeb/Console
[error] 	at java.lang.Class.forName0(Native Method)
[error] 	at java.lang.Class.forName(Class.java:348)
[error] 	at sbt.internal.inc.ModuleUtilities$.getObject(ModuleUtilities.scala:20)
[error] 	at sbt.internal.inc.ModuleUtilities$.getCheckedObject(ModuleUtilities.scala:27)
[error] 	at sbt.internal.inc.ModuleUtilities$.$anonfun$getCheckedObjects$1(ModuleUtilities.scala:31)
[error] 	at scala.collection.immutable.Stream.$anonfun$map$1(Stream.scala:414)
[error] 	at scala.collection.immutable.Stream$Cons.tail(Stream.scala:1167)
[error] 	at scala.collection.immutable.Stream$Cons.tail(Stream.scala:1157)
[error] 	at scala.collection.generic.Growable.loop$1(Growable.scala:53)
[error] 	at scala.collection.generic.Growable.$plus$plus$eq(Growable.scala:57)
[error] 	at scala.collection.generic.Growable.$plus$plus$eq$(Growable.scala:49)
[error] 	at scala.collection.mutable.ListBuffer.$plus$plus$eq(ListBuffer.scala:185)

And the Scala build, based on Sbt 0.13.13:

dragos@aquarius scala-hydra (topic/hydra-2.12) $ csbt 
Fetching org.scala-sbt:compiler-interface:0.13.13 source artifacts
Fetched org.scala-sbt:compiler-interface:0.13.13 source artifacts
Running sbt 0.13.13
[info] Loading project definition from /Users/dragos/workspace/triplequote/scala-hydra/project/project
[info] Loading project definition from /Users/dragos/workspace/triplequote/scala-hydra/project
[info] Updating scala-hydra-build
https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bnd/2.4.1/biz.aQute.bnd-2.4.1.pom
  100.0% [##########] 1.5 KiB (11.9 KiB / s)
https://repo1.maven.org/maven2/com/typesafe/mima-reporter_2.10/0.1.12/mima-reporter_2.10-0.1.12.pom
  100.0% [##########] 1.9 KiB (14.8 KiB / s)
https://repo1.maven.org/maven2/com/typesafe/mima-core_2.10/0.1.12/mima-core_2.10-0.1.12.pom
  100.0% [##########] 1.8 KiB (97.5 KiB / s)
[info] Resolved scala-hydra-build dependencies
[info] Fetching artifacts of scala-hydra-build
https://repo1.maven.org/maven2/com/typesafe/mima-reporter_2.10/0.1.12/mima-reporter_2.10-0.1.12.jar
  100.0% [##########] 170.3 KiB (2.1 MiB / s)
https://repo1.maven.org/maven2/com/typesafe/mima-core_2.10/0.1.12/mima-core_2.10-0.1.12.jar
  100.0% [##########] 313.3 KiB (2.4 MiB / s)
https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bnd/2.4.1/biz.aQute.bnd-2.4.1.jar
  100.0% [##########] 2.5 MiB (6.9 MiB / s)
[info] Fetched artifacts of scala-hydra-build
[info] Compiling 16 Scala sources to /Users/dragos/workspace/triplequote/scala-hydra/project/target/scala-2.10/sbt-0.13/classes...
sbt.InvalidComponent: Could not find required component 'xsbti'
	at sbt.ComponentManager.invalid(ComponentManager.scala:57)
	at sbt.ComponentManager.sbt$ComponentManager$$notFound$1(ComponentManager.scala:34)
	at sbt.ComponentManager.sbt$ComponentManager$$createAndCache$1(ComponentManager.scala:37)
	at sbt.ComponentManager$$anonfun$sbt$ComponentManager$$fromGlobal$1$1.apply(ComponentManager.scala:27)
	at sbt.ComponentManager$$anonfun$sbt$ComponentManager$$fromGlobal$1$1.apply(ComponentManager.scala:26)
	at sbt.ComponentManager$$anon$1.call(ComponentManager.scala:50)
	at coursier.sbtlauncher.DummyGlobalLock$.apply(DummyGlobalLock.scala:18)
	at sbt.ComponentManager.lock(ComponentManager.scala:50)
	at sbt.ComponentManager.lockGlobalCache(ComponentManager.scala:49)
	at sbt.ComponentManager.sbt$ComponentManager$$fromGlobal$1(ComponentManager.scala:25)
	at sbt.ComponentManager$$anonfun$files$1$$anonfun$apply$2.apply(ComponentManager.scala:44)
	at sbt.ComponentManager$$anonfun$files$1$$anonfun$apply$2.apply(ComponentManager.scala:44)
	at sbt.ComponentManager.sbt$ComponentManager$$getOrElse$1(ComponentManager.scala:32)
	at sbt.ComponentManager$$anonfun$files$1.apply(ComponentManager.scala:44)
	at sbt.ComponentManager$$anonfun$files$1.apply(ComponentManager.scala:44)
	at sbt.ComponentManager$$anon$1.call(ComponentManager.scala:50)
	at coursier.sbtlauncher.DummyGlobalLock$.apply(DummyGlobalLock.scala:18)
	at sbt.ComponentManager.lock(ComponentManager.scala:50)
	at sbt.ComponentManager.lockLocalCache(ComponentManager.scala:47)
	at sbt.ComponentManager.files(ComponentManager.scala:44)
	at sbt.compiler.IvyComponentCompiler$$anonfun$sbt$compiler$IvyComponentCompiler$$compileAndInstall$1.apply(ComponentCompiler.scala:114)
	at sbt.compiler.IvyComponentCompiler$$anonfun$sbt$compiler$IvyComponentCompiler$$compileAndInstall$1.apply(ComponentCompiler.scala:111)
	at sbt.IO$.withTemporaryDirectory(IO.scala:344)
	at sbt.compiler.IvyComponentCompiler.sbt$compiler$IvyComponentCompiler$$compileAndInstall(ComponentCompiler.scala:111)
	at sbt.compiler.IvyComponentCompiler$$anonfun$apply$1.apply$mcV$sp(ComponentCompiler.scala:102)
	at sbt.IfMissing$Define.apply(ComponentManager.scala:75)
	at sbt.ComponentManager.sbt$ComponentManager$$createAndCache$1(ComponentManager.scala:39)
	at sbt.ComponentManager$$anonfun$sbt$ComponentManager$$fromGlobal$1$1.apply(ComponentManager.scala:27)
	at sbt.ComponentManager$$anonfun$sbt$ComponentManager$$fromGlobal$1$1.apply(ComponentManager.scala:26)
	at sbt.ComponentManager$$anon$1.call(ComponentManager.scala:50)
	at coursier.sbtlauncher.DummyGlobalLock$.apply(DummyGlobalLock.scala:18)
	at sbt.ComponentManager.lock(ComponentManager.scala:50)
	at sbt.ComponentManager.lockGlobalCache(ComponentManager.scala:49)
	at sbt.ComponentManager.sbt$ComponentManager$$fromGlobal$1(ComponentManager.scala:25)
	at sbt.ComponentManager$$anonfun$files$1$$anonfun$apply$2.apply(ComponentManager.scala:44)
	at sbt.ComponentManager$$anonfun$files$1$$anonfun$apply$2.apply(ComponentManager.scala:44)
	at sbt.ComponentManager.sbt$ComponentManager$$getOrElse$1(ComponentManager.scala:32)
	at sbt.ComponentManager$$anonfun$files$1.apply(ComponentManager.scala:44)
	at sbt.ComponentManager$$anonfun$files$1.apply(ComponentManager.scala:44)
	at sbt.ComponentManager$$anon$1.call(ComponentManager.scala:50)
	at coursier.sbtlauncher.DummyGlobalLock$.apply(DummyGlobalLock.scala:18)
	at sbt.ComponentManager.lock(ComponentManager.scala:50)
	at sbt.ComponentManager.lockLocalCache(ComponentManager.scala:47)
	at sbt.ComponentManager.files(ComponentManager.scala:44)
	at sbt.ComponentManager.file(ComponentManager.scala:53)
	at sbt.compiler.IvyComponentCompiler.apply(ComponentCompiler.scala:102)
	at sbt.compiler.ComponentCompiler$$anon$2.apply(ComponentCompiler.scala:35)
	at sbt.compiler.AnalyzingCompiler.loader(AnalyzingCompiler.scala:118)
	at sbt.compiler.AnalyzingCompiler.getInterfaceClass(AnalyzingCompiler.scala:128)
	at sbt.compiler.AnalyzingCompiler.call(AnalyzingCompiler.scala:104)
	at sbt.compiler.AnalyzingCompiler.newCachedCompiler(AnalyzingCompiler.scala:62)
	at sbt.compiler.AnalyzingCompiler.newCachedCompiler(AnalyzingCompiler.scala:57)
	at sbt.compiler.CompilerCache$$anon$2.apply(CompilerCache.scala:47)
	at sbt.compiler.AnalyzingCompiler.compile(AnalyzingCompiler.scala:45)
	at sbt.compiler.MixedAnalyzingCompiler$$anonfun$compileScala$1$1.apply$mcV$sp(MixedAnalyzingCompiler.scala:50)
	at sbt.compiler.MixedAnalyzingCompiler$$anonfun$compileScala$1$1.apply(MixedAnalyzingCompiler.scala:50)
	at sbt.compiler.MixedAnalyzingCompiler$$anonfun$compileScala$1$1.apply(MixedAnalyzingCompiler.scala:50)
	at sbt.compiler.MixedAnalyzingCompiler.timed(MixedAnalyzingCompiler.scala:74)
	at sbt.compiler.MixedAnalyzingCompiler.compileScala$1(MixedAnalyzingCompiler.scala:49)
	at sbt.compiler.MixedAnalyzingCompiler.compile(MixedAnalyzingCompiler.scala:64)
	at sbt.compiler.IC$$anonfun$compileInternal$1.apply(IncrementalCompiler.scala:160)
	at sbt.compiler.IC$$anonfun$compileInternal$1.apply(IncrementalCompiler.scala:160)
	at sbt.inc.IncrementalCompile$$anonfun$doCompile$1.apply(Compile.scala:66)
	at sbt.inc.IncrementalCompile$$anonfun$doCompile$1.apply(Compile.scala:64)
	at sbt.inc.IncrementalCommon.cycle(IncrementalCommon.scala:32)
	at sbt.inc.Incremental$$anonfun$1.apply(Incremental.scala:72)
	at sbt.inc.Incremental$$anonfun$1.apply(Incremental.scala:71)
	at sbt.inc.Incremental$.manageClassfiles(Incremental.scala:99)
	at sbt.inc.Incremental$.compile(Incremental.scala:71)
	at sbt.inc.IncrementalCompile$.apply(Compile.scala:54)
	at sbt.compiler.IC$.compileInternal(IncrementalCompiler.scala:160)
	at sbt.compiler.IC$.incrementalCompile(IncrementalCompiler.scala:138)
	at sbt.Compiler$.compile(Compiler.scala:155)
	at sbt.Compiler$.compile(Compiler.scala:141)
	at sbt.Defaults$.sbt$Defaults$$compileIncrementalTaskImpl(Defaults.scala:879)
	at sbt.Defaults$$anonfun$compileIncrementalTask$1.apply(Defaults.scala:870)
	at sbt.Defaults$$anonfun$compileIncrementalTask$1.apply(Defaults.scala:868)
	at scala.Function1$$anonfun$compose$1.apply(Function1.scala:47)
	at sbt.$tilde$greater$$anonfun$$u2219$1.apply(TypeFunctions.scala:40)
	at sbt.std.Transform$$anon$4.work(System.scala:63)
	at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:228)
	at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:228)
	at sbt.ErrorHandling$.wideConvert(ErrorHandling.scala:17)
	at sbt.Execute.work(Execute.scala:237)
	at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:228)
	at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:228)
	at sbt.ConcurrentRestrictions$$anon$4$$anonfun$1.apply(ConcurrentRestrictions.scala:159)
	at sbt.CompletionService$$anon$2.call(CompletionService.scala:28)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
[error] (compile:compileIncremental) sbt.InvalidComponent: Could not find required component 'xsbti'
Project loading failed: (r)etry, (q)uit, (l)ast, or (i)gnore? 
@alexarchambault
Copy link
Member

So I updated the launcher and the generate-launcher.sh script (but I guess you already have the right launcher version…)

About the xsbti component missing, I was able to reproduce it… Not sure why I commented out the lines defining that.

About the jdeb error, this looks similar to this coursier issue: coursier/coursier#450, which should have workarounds.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants