Uploaded image for project: 'Scala Programming Language'
  1. Scala Programming Language
  2. SI-10102

Regression on importing multiple wildcard in same line while booting Scala REPL



      I found sbt's initialCommands doesn't work for Scala 2.12. Affected versions are 2.12.0, 2.12.1.

      The `initialCommands` is a feature by sbt but the same one works with Scala 2.11 and 2.10.
      I'm afraid it is due to some issue on Scala 2.12. This is a blocker issue for us when upgrading to 2.12. I hope the issue will be fixed in the next patch release.

      Procedure to reproduce the situation:

      • Prepare skinny blank app

      # macOS
      brew install skinny
      skinny new skinny-blank-app
      # others 
      wget https://github.com/skinny-framework/skinny-framework/releases/download/2.3.1/skinny-blank-app-with-deps.zip
      unzip skinny-blank-app-with-deps.zip
      cd ./skinny-blank-app

      • Switch to Scala 2.12.1

      Manually edit `build.sbt`.

      • invoke sbt console

      In the project, sbt invokes the Scala REPL with the following initialCommands:

      initialCommands := """
      import skinny._
      import _root_.controller._, model._
      import org.joda.time._
      import scalikejdbc._, config._

      `skinny console` just does `sbt dev/console` internally. The `dev` is an sbt sub project.

      ./skinny console

      • outputs

      It fails to run initialCommands and the REPL aborts after that.

      Welcome to Scala 2.12.1 (Java HotSpot(TM) 64-Bit Server VM, Java 1.8.0_71).
      Type in expressions for evaluation. Or try :help.
      scala> 2016-12-11 10:35:02.257 DEBUG   --- [     run-main-0] scalikejdbc.ConnectionPool$              : Registered connection pool : ConnectionPool(url:jdbc:h2:file:./db/development;MODE=PostgreSQL;AUTO_SERVER=TRUE, user:sa) using factory : <default>
      import skinny._
      import _root_.controller._
      import model._
      import org.joda.time._
      import scalikejdbc._
      import config._
      Interpreter encountered errors during initialization!
      [error] (Thread-38) java.lang.InterruptedException
      	at java.util.concurrent.SynchronousQueue.put(SynchronousQueue.java:879)
      	at scala.tools.nsc.interpreter.SplashLoop.run(InteractiveReader.scala:77)
      	at java.lang.Thread.run(Thread.java:745)
      [success] Total time: 36 s, completed Dec 11, 2016 10:35:10 AM


          Issue Links



              • Assignee:
                apm A. P. Marki
                seratch Kazuhiro Sera
              • Votes:
                1 Vote for this issue
                5 Start watching this issue


                • Created: