"sbt '++ 2.13.0-M2!' compile" does not work with sbt 1.0.0
See original GitHub issuesteps
- https://github.com/xuwei-k/sbt-1-cross-bug
- https://travis-ci.org/xuwei-k/sbt-1-cross-bug/builds/263752411
project/build.properties
sbt.version=1.0.0
build.sbt
scalaVersion := "2.12.3"
Foo.scala
package example
class Foo
execute sbt '++ 2.13.0-M2!' compile
problem
[info] Forcing Scala version to 2.13.0-M2 on all projects.
[info] Reapplying settings...
[info] Set current project to sbt-1-cross-bug (in build file:/home/travis/build/xuwei-k/sbt-1-cross-bug/)
[info] Updating {file:/home/travis/build/xuwei-k/sbt-1-cross-bug/}sbt-1-cross-bug...
[info] Done updating.
[info] Compiling 1 Scala source to /home/travis/build/xuwei-k/sbt-1-cross-bug/target/scala-2.13.0-M2/classes ...
[info] Non-compiled module 'compiler-bridge_2.12' for Scala 2.13.0-M2. Compiling...
/tmp/sbt_a4c7a1d5/xsbt/ConsoleInterface.scala:11: error: object ILoop is not a member of package scala.tools.nsc.interpreter
import scala.tools.nsc.interpreter.{ ILoop, IMain, InteractiveReader }
^
/tmp/sbt_a4c7a1d5/xsbt/ConsoleInterface.scala:41: error: not found: type ILoop
val loop = new ILoop {
^
/tmp/sbt_a4c7a1d5/xsbt/ConsoleInterface.scala:44: error: not found: value in
in = InteractiveReader.apply()
^
/tmp/sbt_a4c7a1d5/xsbt/ConsoleInterface.scala:45: error: not found: value intp
intp = new IMain(settings) {
^
/tmp/sbt_a4c7a1d5/xsbt/ConsoleInterface.scala:52: error: not found: value intp
intp.setContextClassLoader()
^
/tmp/sbt_a4c7a1d5/xsbt/ConsoleInterface.scala:54: error: value createInterpreter is not a member of AnyRef
super.createInterpreter()
^
/tmp/sbt_a4c7a1d5/xsbt/ConsoleInterface.scala:57: error: not found: value intp
intp.beQuietDuring(intp.bind(id, value.asInstanceOf[AnyRef].getClass.getName, value))
^
/tmp/sbt_a4c7a1d5/xsbt/ConsoleInterface.scala:57: error: not found: value intp
intp.beQuietDuring(intp.bind(id, value.asInstanceOf[AnyRef].getClass.getName, value))
^
/tmp/sbt_a4c7a1d5/xsbt/ConsoleInterface.scala:60: error: not found: value intp
intp.interpret(initialCommands)
^
/tmp/sbt_a4c7a1d5/xsbt/ConsoleInterface.scala:67: error: not found: value intp
intp.interpret(cleanupCommands)
^
/tmp/sbt_a4c7a1d5/xsbt/InteractiveConsoleHelper.scala:10: error: object IR is not a member of package scala.tools.nsc.interpreter
import scala.tools.nsc.interpreter.IR
^
/tmp/sbt_a4c7a1d5/xsbt/InteractiveConsoleHelper.scala:14: error: not found: value IR
implicit def toConsoleResult(ir: IR.Result): InteractiveConsoleResult =
^
/tmp/sbt_a4c7a1d5/xsbt/InteractiveConsoleHelper.scala:16: error: not found: value IR
case IR.Success => InteractiveConsoleResult.Success
^
/tmp/sbt_a4c7a1d5/xsbt/InteractiveConsoleHelper.scala:17: error: not found: value IR
case IR.Incomplete => InteractiveConsoleResult.Incomplete
^
/tmp/sbt_a4c7a1d5/xsbt/InteractiveConsoleHelper.scala:18: error: not found: value IR
case IR.Error => InteractiveConsoleResult.Error
^
/tmp/sbt_a4c7a1d5/xsbt/InteractiveConsoleInterface.scala:41: error: type mismatch;
found : java.io.PrintWriter
required: scala.tools.nsc.interpreter.ReplReporter
val interpreter: IMain = new IMain(compilerSettings, new PrintWriter(outWriter)) {
^
/tmp/sbt_a4c7a1d5/xsbt/InteractiveConsoleInterface.scala:48: error: type mismatch;
found : tools.nsc.interpreter.Results.Result
required: xsbti.InteractiveConsoleResult
InteractiveConsoleResponse(r, outWriter.toString)
^
17 errors found
[info] Attempting to fetch org.scala-sbt:compiler-bridge_2.12:1.0.0.
[info] downloading https://repo1.maven.org/maven2/org/scala-sbt/compiler-bridge_2.12/1.0.0/compiler-bridge_2.12-1.0.0-sources.jar ...
[info] [SUCCESSFUL ] org.scala-sbt#compiler-bridge_2.12;1.0.0!compiler-bridge_2.12.jar(src) (35ms)
[error] (compile:compileIncremental) Error compiling the sbt component 'compiler-bridge_2.12'
[error] Total time: 19 s, completed Aug 12, 2017 5:48:00 AM
expectation
compile success
notes
sbt version: 1.0.0
Issue Analytics
- State:
- Created 6 years ago
- Comments:8 (8 by maintainers)
Top Results From Across the Web
sbt Reference Manual — sbt 1.0.x releases
sbt 1.0.x releases. sbt 1.0.4. This is a hotfix release for sbt 1.0.x series. Bug fixes. Fixes undercompilation of value classes when the...
Read more >Scala 2.13, SBT: sbt compile uses wrong compiler version
So, my problem was actually very simple. Turns out you need to start sbt in a project root directory (where build.sbt is located)....
Read more >eed3si9n
sbt 1.x is released under Semantic Versioning, and the plugins are expected to work throughout the 1.x series. Please try it out, and...
Read more >Incremental conversion to Scala 3 - Question
You can not use a different compiler for a single file, this wasn't even true for minor ... I changed “2.13.4” to “3.0.0-M3”...
Read more >Announcing Scala.js 1.0.0-M8
Moreover, this release is not entirely source compatible with 0.6.x either ... Add addSbtPlugin("org.scala-js" % "sbt-scalajs-env-phantomjs" ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Theoretically, we ship hotfixes as often as we get fixes merged. We’ve been accumulating a bunch of fixes, so 1.0.3 needs to ship like today. 1.0.4 can follow up next week if someone spends 1h on this fix.
Fixed in https://github.com/sbt/zinc/pull/453 / https://github.com/sbt/sbt/pull/3768