Scala Center Update: May 2020

(The Scala Center team is dedicated to providing regular and transparent community updates about project plans & progress. In this forum we created a new topic category to allow quicker orientation going forward: “Scala Center Updates”. Even though all feedback is welcome, we keep the right to make executive decisions about projects we lead. Overview of all our activities can always be found at https://scala.epfl.ch/records.html)

Activity update for May 2020

Education

  • Experimenting lessons in the form of interactive notebooks on the Coursera platform. This approach makes it possible to execute any Scala snippet in the middle of a lesson, and lets learners play with the snippets and see the changes in the result.
  • Implemented the automated grader for the assignment of the first week of the “Effective programming in Scala” course. This course aims to provide a fast track to learning Scala, and shows the best practices and common patterns.
  • Reviewed Lunatech’s course about migrating from Scala 2 to Scala 3. This hands-on course shows how to take advantage of the new features of Scala 3 in a real project.
  • Maintaining the “Functional Program Design in Scala” course to improve the assignments based on the feedback we got from the learners.

Dotty

  • Fixed a number of issues with SemanticDB generation in Dotty (see #8983). In Dotty’s test suite all compilation tests now use the -Ydemanticdb compiler option, including the compiler itself. It means that any changes to the language will be automatically tested against SemanticDB generation. Validation will still require explicit checkfile based tests.
  • Minimized and reported a few issues in Dotty’s type inference algorithm (see #8801, #8802, #8933).
  • Published a blog article presenting the new “import suggestions” of the Scala 3 compiler and how it can help you to solve the “implicit not found” problems.

Scala.js

  • Released Scala.js 0.6.33 and 1.1.0. The latter features @js.native vals and defs, a very appreciated feature.
  • Released sbt-jsdependencies 1.0.1 and scalajs-env-jsdom-nodejs 1.1.0 with critical bug fixes, notably for a bad interaction with React.js’ development mode.
  • Updating the Hands-on Scala.js book for Scala.js 1.x (ongoing).

We would like to bring your attention to the fact we intend to discontinue the Scala.js 0.6.x series, leaving v0.6.33 as the last 0.6.x version. Please speak up at #4045 if this is a problem for you.

Scala Native

  • Reviewing and merging a lot of pending pull requests. Contributors are really happy to see this happening.
  • Refactored the testing framework by using reflective instanciation instead of source generation (see #1802)

The Scala Native roadmap has been published to Scala contributors. The next steps for the next two months are:

  • Adding JUnit support in Scala Native (mostly ported from Scala.js) to allow for more libraries to be easily ported to Scala Native
  • Working towards Scala 2.12 support to make Scala 2.12 libraries portable to Scala Native

TASTy Reader for Scala 2

  • Updated TASTy reader to be compatible with the latest official release of Dotty: 0.24.0-RC1.
  • Investigating the possibility of Def macros in TASTy. LAMP added support in a Nightly Dotty for Scala 2 macro definitions and a branch of TASTy Reader uses the definition to bootstrap and run the macro. This will be merged with the main development branch when the next official Dotty release is out. More work is necessary to decide how type inference issues with Macro bundles can be handled.

JSR-45 for improved Scala debugging experience

The JSR-45 implementation roadmap has been published to Scala contributors.

The idea is to mimic what Kotlin does with JSR-45 on its side. We believe that this is a good solution, because it is elegant and relatively easy to implement. We expect to have most of the functionality in place by the end of June 2020.

Metals

New features:

  • Ammonite support in Metals (see the post in Scala contributors)
  • New project provider to improve the beginner experience (see #1728)
  • Improved multiline string formatting (see #1753)

Improvements and bug fixes:

  • Investigating deduplication issues inside Bloop (see #1140)
  • Made the integration between Metals and Bloop smoother (see #1677)
  • Providing support on the scalameta parser for Scala 3
  • Fixing miscellaneous bugs on Scala 2 and Scala 3 support in Metals

Scalafix

  • Cross-built scalafix in 2.13 (see #1120)
  • Released scalafix 0.9.13 (see #109)

BSP in sbt

The following features have been implemented and merged in sbt (see #5538):

  • The minimum viable subset of BSP endpoints for Metals and the IntelliJ Scala plugin
  • The compiler diagnostic notifications.
  • The compile taskStart and taskFinish notifications.
  • The Build Server Discovery protocol.

The sbt BSP server can be tried out by fetching the sbt master branch and running the publishLocal task to create sbt version 1.4.0-SNAPSHOT locally.

Dependency management tooling

13 Likes