sbt 1.2.3 patch release

By Eugene Yokota (@eed3si9n) September 14, 2018

Hi everyone. sbt 1.2.3 patch release is available.

How to upgrade

Change project/build.properties as follows:

sbt.version=1.2.3

The sbt launcher will automatically resolve sbt 1.2.3 based on what’s in project/build.properties.

However, if you want to resolve sbt 1.2.3 faster, you should use the installers. zip, tgz, and msi installers contain all the JAR files so the resolution completes from the preloaded-local repository.

Position

Adds startOffset and endOffset fields to xsbti.Position datatype, which is used to carry compiler warnings between Scala compiler and Zinc. When -Yrangepos flag is enabled, this enables squiggles to be displayed across the expression in VS Code.

To check this out, first add the following line in build.sbt:

ThisBuild / Compile / scalacOptions += "-Yrangepos"

Before an error message looked like this on VS Code Scala (sbt) plugin:

rangepos

Using sbt 1.2.3 the squiggle looks like this:

rangepos

This enhancement was contributed by Guillaume Martres (@smarter) from EPFL Scala team as zinc#580 and util#173 with some follow-up #4354 by @eed3si9n. This will also help Dotty and its IDE support on VS Code, which is planned to be used for CS 210 Functional Programming class at EPFL this Fall semester!

Note: Enabling "-Yrangepos" comes with some performance penalty (about 10%) in Scala 2.12.6. There’s a performance improvement planned for 2.12.7.

Other bug fixes and enhancements

  • Optimizes Zinc by avoiding regex for a common case zinc#595 by @retronym
  • Fixes a typo in “PUT operation failed” error message lm#261 by @Philippus
  • Adds scalaCompilerBridgeBinaryJar task for Dotty compiler bridge #4332 by @smarter from EPFL Scala team

Participation

Thanks to everyone who’s helped improve sbt and Zinc 1 by using them, reporting bugs, improving our documentation, porting builds, porting plugins, and submitting and reviewing pull requests.

For anyone interested in helping sbt, there are many avenues for you to help, depending on your interest.

  • Help someone at work or online fix their build problem.
  • Answer StackOverflow questions.
  • Report issues.
  • Maintain and update documentation.
  • Garden issue tracker.
  • Patch the core (send pull requests to code).

If you’re interested, Contributing, “help wanted”, “good first issue” are good starting points. If you have ideas, come talk to us on sbt-contrib or on Lightbend Discuss.