Pants 1.x had a long history of support for Java and Scala, going back to when it was first created at Twitter. In fact: they were the first supported

Pants 2.9: Alpha support for Java and Scala, improvements for Docker and Go, and more

submited by
Style Pass
2022-01-13 17:30:07

Pants 1.x had a long history of support for Java and Scala, going back to when it was first created at Twitter. In fact: they were the first supported languages! Consequently, (re-)adding support for these popular JVM languages has been high on our list ever since the 2.x release in late 2020.

In the last few years, we’ve learned a lot about how best to deal with more-slowly-compiling, high level languages like Scala.

But very fine-grained, always-accurate dependencies also enable per-file compilation, reducing the number of files that Pants needs to feed to scalac, and allowing for automatic file-level parallelization and the most accurate cache keys possible. From a correctness perspective, that means that unlike tools which use compilation libraries like Zinc (SBT, Bloop, Mill, optionally Bazel, and others) Pants 2.9.0 supports sandboxed, minimal incremental Java and Scala compilation, while preventing the under-compilation bugs that have historically troubled Scala developers.

Another significant improvement for the JVM over 1.x is that Pants 2.9 implements a monorepo-friendly multiple-resolve/lockfile strategy for third party dependencies, allowing for correctness, flexibility, and performance.

Leave a Comment