Skip to content

Update dependency sbt/sbt to v2.1.0 - #931

Open
renovate[bot] wants to merge 1 commit into
mainfrom
renovate/sbt-sbt-2.x
Open

renovate[bot] wants to merge 1 commit into
mainfrom
renovate/sbt-sbt-2.x

Conversation

@renovate

@renovate renovate Bot commented Nov 16, 2026

Copy link
Copy Markdown
Contributor

Note

This PR body was truncated due to platform limits.

This PR contains the following updates:

Package Update Change
sbt/sbt minor 2.0.12 → 2.1.0

Warning

Some dependencies could not be looked up. Check the Dependency Dashboard for more information.


Release Notes

sbt/sbt

v2.1.0: 2.1.0

Compare Source

Changes with compatibility implications

  • Metabuild is updated to Scala 3.9.
  • Apache Ivy is removed from the dependency.
Scala 3.9

sbt 2.1.0 updates the Scala version used by the metabuild to Scala 3.9.0 LTS.

Since both sbt 2.x and Scala 3.x are only backward compatible across minor versions, appropriate Scala version must be used for building sbt plugins:

sbt 2.x Scala 3.x Plugin works on sbt 2.0.x Works on sbt 2.1.x
2.0.x 3.8.x ✅ ✅
2.1.0 3.9.x ❌ ✅

While publishing plugins using sbt 2.1.0 would mean that it would no longer be compatible with sbt 2.0.x, given that Scala 3.9 is an LTS that will be supported for the next 3 years, we should use it as a new baseline. Here's how to set the minimal sbt version for your plugin:

pluginCrossBuild / sbtVersion := {
  scalaBinaryVersion.value match {
    case "2.12" => "1.9.9"
    case _      => "2.1.0"
  }
}
Publishing

sbt 2.1.0 removes Apache Ivy from its transitive dependency, and implements Ivyless publishing.

This was contributed by @​bitloi, @​fury0928, @​BrianHotopp, @​mkurz, @​stasimus, @​jozanek, and @​eed3si9n in #​8686, #​8866, #​8894, #​8975, #​8988, #​8996, #​9069, #​9463, and #​9533, #​9615, #​9756, #​9804, #​9806, #​9811, #​9814 etc.

Test summary

When tests are executed, sbt 2.1.0 displays a test summary at the end, listing the failed test suites as follows:

[error] Test summary (2 test tasks failed):
[error]   a / Test / testQuick
[error]         com.example.a.TestA     FAIL
[error]   b / Test / testQuick
[error]         com.example.b.TestB     FAIL
[error]
[error] failed: total 4, failed 2, errors 0, passed 2, cached 2

Successful tests will display only a terse summary by default:

[info] passed: total 4, failed 0, errors 0, passed 4, cached 4

--test_summary=success can override the behavior to list the successful test as well. Test summary was contributed by @​eed3si9n and @​BrianHotopp in #​9602 + #​9214.

Test cache opt-out

sbt 2.1.0 can let you opt out of test result caching:

$ sbt test --cache_test_result=false

This was contributed by @​anatoliykmetyuk in #​9675.

workerMaxInstances and testTopology

sbt 2.1.0 adds new settings workerMaxInstances and testTopology to control test scheduling,
especially of the forked tests. Use Global / workerMaxInstances to change the number of worker instances. The default is set to 2:

// or sbt -Dsbt.worker_max_instances=2
Global / workerMaxInstances := 2

Use the testTopology setting to control whether you want to split the test classes into multiple workers or keep them together. The default was changed to split to 2 groups:

Test / testTopology := TestTopology.subprojectSplit(2)

To keep all classes in a subproject on one worker instead, use:

Test / testTopology := TestTopology.subprojectExclusive

This was contributed by @​eed3si9n in #​9665

clean task

sbt 2.1.0 updates the clean task to act as a cache invalidator. Regardless of the cache state, running clean would invalidate the cache for the next command execution. This can be scoped to subproject or configuration:

$ sbt foo/clean
$ sbt foo/compile

This was contributed by @​eed3si9n in #​9752

Source dependency update

sbt 2.1.0 provides better control to handle source dependencies.

This was contributed by @​seroperson in #​8880.

Identity map optimization

In sbt 2.1.0, a key assignment (:=) whose right-hand side is expr.value short-circuits to x.set(expr).
This is helpful in avoiding JsonFormat[A] when expr is an uncached task.

This was contributed by @​eed3si9n in #​9831

Task-level caching opt-out

// opt out of compilation cache
Compile / compile / cacheStores := Nil
Test / compile / cacheStores := Nil

// opt out of test cache
Test / test / cacheStores := Nil

This was contributed by @​eed3si9n in #​9874

Input-only cache

sbt 2.1.0 introduces a new cache level CacheLevelTag.InputOnly:

@cacheLevel(include = Array(CacheLevelTag.InputOnly))
val scalacOptions = taskKey[Seq[String]]("Options for the Scala compiler.")

Similar to Def.uncached(...), scalacOptions will evaluate each time, but scalacOptions.value will participate as an input to other cached task.

This was contributed by @​eed3si9n in #​9953

HTTP Bazel cache

sbt 2.1.0 adds support for HTTP Bazel cache, in addition to gPRC.

Global / remoteCache := Some(uri("http://127.0.0.1:8000"))

This was contributed by @​eed3si9n in #​9880

🚀 Other updates

🐛 Bug fixes

Zinc bug fixes

⚡ Performance improvements

Behind the scenes

[!IMPORTANT]
✂ PR body was truncated to here.


Configuration

📅 Schedule: (UTC)

  • Branch creation
    • At any time (no schedule defined)
  • Automerge
    • At any time (no schedule defined)

🚦 Automerge: Enabled.

♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate
renovate Bot enabled auto-merge November 16, 2026 21:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants