Commit Graph

17565 Commits

Author SHA1 Message Date
gayanMatch 65af6c59d6 Fix #3746: Scripted should fail when no tests match the pattern 2026-01-09 13:57:58 -06:00
MkDev11 061145e67b
[2.x] Add testForkedParallelism setting for forked test thread count (#8453)
**Problems**

When running forked tests, sbt uses `Runtime.getRuntime().availableProcessors()` to determine the thread pool size, ignoring `concurrentRestrictions`. This is inconsistent with non-forked parallel tests.

**Expectations**

Users should be able to control the number of parallel test threads in forked mode, similar to how `concurrentRestrictions` works for non-forked tests.

**Notes**

Added a new setting `testForkedParallelism` that allows explicit control:

```scala
testForkedParallelism := Some(2)  // Use 2 threads
testForkedParallelism := None     // Use availableProcessors() (default)
```
2026-01-09 12:43:50 -05:00
eugene yokota 7320b7176a
Merge pull request #8443 from xuwei-k/deprecated-scala-App 2026-01-09 08:15:11 -05:00
xuwei-k 2d14adc721 avoid deprecated scala.App
7ddf329f6f/library/src/scala/App.scala (L65)
2026-01-09 20:10:28 +09:00
eugene yokota 66aebdb96b
Merge pull request #8454 from calm329/fix/parse-key-spec-flaky-8326 2026-01-09 01:27:18 -05:00
calm329 79b54a28ce Fix ParseKeySpec flaky test when task name matches project name (#8326) 2026-01-08 20:55:14 -08:00
eugene yokota b537afee76
Merge pull request #8452 from calm329/fix/8441-jna-nosys-conditional
[2.x] Fix #8441: Allow system JNA on OpenBSD by making jna.nosys conditional
2026-01-08 20:07:22 -05:00
calm 8c20401fb9
[2.x] Report eviction errors for Test dependencies (#8451)
Eviction warnings and errors were not reported for Test dependencies because
`EvictionError` only checked the Compile configuration.

This fix runs the eviction check for both Compile and Test configurations
separately, with distinct error messages:

- Compile: `found version conflict(s) in library dependencies`
- Test: `found version conflict(s) in Test dependencies`
2026-01-08 20:01:18 -05:00
calm329 1054ee851e Fix #8441: Allow system JNA on OpenBSD by making jna.nosys conditional 2026-01-08 15:19:36 -08:00
eugene yokota 997ad9619a
Merge pull request #8446 from Angel98518/fix-sbt-version-flag
[2.x] Fix --sbt-version to expand to -Dsbt.version
2026-01-08 18:16:14 -05:00
eugene yokota 9570cc9b05
Merge pull request #8450 from sbt/eed3si9n-patch-1
[2.x] Update README with DEVELOPING document reference
2026-01-08 15:32:17 -05:00
eugene yokota 8388fae512
Update README with DEVELOPING document reference
Added a link to the DEVELOPING document for contribution guidelines.
2026-01-08 15:22:21 -05:00
Angel98518 938b5f97f0 Trigger CLA check 2026-01-08 20:59:27 +01:00
eugene yokota 200293a0f5
Merge pull request #8449 from sbt/eed3si9n-patch-1
[2.x] docs: Replace sbt-contrib link with Discussions link
2026-01-08 14:58:23 -05:00
eugene yokota acf4e7df6b
Replace sbt-contrib link with Discussions link
Updated contribution guidelines to reflect new discussion process.
2026-01-08 14:57:55 -05:00
Angel98518 a0f5c83e79 Fix --sbt-version to expand to -Dsbt.version
Fixes #6645

The --sbt-version flag was incorrectly trying to download an sbt launcher
with the specified version, which doesn't exist for many sbt versions.

Changes:
- Modified --sbt-version handling to directly add -Dsbt.version property
- Removed sbt_version variable assignment that caused launcher mismatch
- acquire_sbt_jar now uses default launcher version instead

Now --sbt-version X.Y.Z correctly expands to -Dsbt.version=X.Y.Z without
affecting the sbt launcher version used to run the build.
2026-01-08 20:51:27 +01:00
eugene yokota df90cb967c
Merge pull request #8447 from Francluob/fix/8344-batch-mode-load-failed-prompt
[2.x] fix: Skips interactive prompt in batch mode when project loading
2026-01-08 14:17:20 -05:00
Francluob 4976ec7dc7 Fix #8344: Skip interactive prompt in batch mode when project loading fails
When project loading fails in batch mode, sbt was showing an interactive
prompt asking the user to choose between retry, quit, last, or ignore.
However, in batch mode there is no interactive terminal, causing the
process to hang waiting for input that will never come.

This fix checks if we're in batch mode (Prompt.Batch) and automatically
exits with failure (equivalent to 'q' quit option) without prompting the
user. This prevents infinite retry loops on persistent errors and allows
batch mode scripts to fail fast, which is appropriate for CI/CD environments.

The interactive behavior remains unchanged for non-batch mode.
2026-01-08 19:29:35 +01:00
aka James4u a4ad73ddf6
fix: prevent server boot when --no-server is used (#8444)
* fix: prevent server boot when --no-server is used
* refactor: move serverAutoStart to sysprops
* refact: scalafmt
2026-01-07 15:11:04 -05:00
eugene yokota 948f12cf54
Merge pull request #8440 from MkDev11/fix/windows-debug-options-8100
[2.x] Fix debug options breaking launcher on Windows
2026-01-06 15:48:07 -05:00
mkdev11 79ab58f4af Add regression test for debug options in SBT_OPTS (#8100) 2026-01-06 14:21:03 +02:00
mkdev11 17f03201d3 Fix debug options breaking launcher on Windows
Filter rt-ext-dir output for java9-rt-ext- pattern, matching the
Unix script behavior. This prevents debug agent stdout (e.g.,
'Listening for transport dt_socket at address: 1234') from being
incorrectly parsed as a file path.

Fixes #8100
2026-01-06 11:00:25 +02:00
eugene yokota 7e59872d31
Merge pull request #8437 from eed3si9n/wip/bump-zinc
[2.x] Zinc 2.0.0-M11
2026-01-05 01:20:37 -05:00
Eugene Yokota f49b6747c7 [2.x] Zinc 2.0.0-M11 2026-01-05 01:01:37 -05:00
eugene yokota 4a39f0c41b
Merge pull request #8436 from eed3si9n/wip/merge-1.12.x
[2.x] Merge 1.12.x
2026-01-05 00:34:15 -05:00
Eugene Yokota e3f99d39cb Merge branch '1.12.x' into wip/merge-1.12.x 2026-01-05 00:08:21 -05:00
Eugene Yokota fcb4e0e43c sbt 1.12.0 2026-01-04 21:18:03 -05:00
eugene yokota 6f50a1efca
Merge pull request #8434 from eed3si9n/wip/bump
[1.x] Zinc 1.12.0
2026-01-04 21:04:04 -05:00
Eugene Yokota 0e546f0b35 [1.x] Zinc 1.12.0 2026-01-04 20:50:33 -05:00
eugene yokota 2e8e03eb0e
Merge pull request #8432 from eed3si9n/bport/scala-version
[1.x] Show warnings when scalaVersion is missing
2026-01-04 15:34:43 -05:00
eugene yokota 457127a090
Merge pull request #8431 from eed3si9n/wip/fork-test
[2.x] fix: Use TCP for forked test
2026-01-04 15:24:09 -05:00
Eugene Yokota 0a15069e83 Show warnings when scalaVersion is missing
**Problem**
There's a disconnect between what is perceived to be the current
Scala version, and what sbt uses internally, and thus what it
chooses to be the default scalaVersion.

**Solution**
This displays a warning if scalaVersion setting is missing.
2026-01-04 15:23:05 -05:00
Eugene Yokota c20d83a8e2 Use TCP for the fork test
**Problem**
Forked test currently uses stdio, but that println to be lost.

**Solution**
Use TCP for communication similar to sbt 1.x.
2026-01-04 01:48:45 -05:00
eugene yokota 2b404d6a60
Merge pull request #8428 from eed3si9n/wip/scala-version
[2.x] Show warnings when scalaVersion is missing
2025-12-28 00:07:16 -05:00
Eugene Yokota 6cb786d010 [2.x] Show warnings when scalaVersion is missing
**Problem**
There's a disconnect between what is perceived to be the current
Scala version, and what sbt uses internally, and thus what it
chooses to be the default scalaVersion.

**Solution**
This displays a warning if scalaVersion setting is missing.
2025-12-27 23:49:43 -05:00
Eugene Yokota 55aa1b52ff Disable task-cancel test 2025-12-27 02:37:32 -05:00
eugene yokota 48f96dfbd5
Merge pull request #8427 from eed3si9n/wip/no-such
[2.x] fix: Workaround for NoSuchFileException
2025-12-25 04:57:48 -05:00
Eugene Yokota 7d76f8f33e [2.x] fix: Workaround for NoSuchFileException
**Problem**
In some scripted tests, we've seen NoSuchFileException.

**Solution**
Catch the exceptions related to caching.
2025-12-25 04:38:43 -05:00
eugene yokota 65605efc8b
Merge pull request #8426 from eed3si9n/wip/reprop-lm-bug
[2.x] fix: Resolver.combineDefaultResolvers
2025-12-25 04:05:42 -05:00
Eugene Yokota a9e38e3a1c [2.x] fix: Resolver.combineDefaultResolvers
**Problem**
combineDefaultResolvers loses information.

**Solution**
This fixes it.
2025-12-25 01:49:57 -05:00
Eugene Yokota 67e52c3006 sbt 1.12.0-RC1 2025-12-19 23:46:35 -05:00
eugene yokota 5b92e34dbd
Merge pull request #8422 from eed3si9n/wip/crosspath
[2.x] fix: Replace Scala version with u when crossPaths is false
2025-12-19 03:11:09 -05:00
eugene yokota b926c84c1d
Merge pull request #8425 from eed3si9n/wip/bump-lm
[1.x] Update to lm 1.12.0-M2
2025-12-19 02:45:19 -05:00
Eugene Yokota fb37b9c66b [1.x] Update to lm 1.12.0-M2 2025-12-19 02:02:16 -05:00
eugene yokota b536bc037d
Merge pull request #8359 from eed3si9n/wip/dependency-tree
[1.x] Use internal config for dependency tree (for Provided)
2025-12-19 01:08:44 -05:00
eugene yokota 2fad041c5f
Merge pull request #8424 from eed3si9n/wip/bump-zinc
[1.x] Update to Zinc 1.12.0-M2
2025-12-19 00:47:17 -05:00
Eugene Yokota 7bb5180f9e [1.x] Update to 1.12.0-M2 2025-12-19 00:23:07 -05:00
eugene yokota 7fb942ee5c
Merge pull request #8423 from Duhemm/help-arg-parsing
[2.x] Fix `help` command arguments parsing
2025-12-18 21:14:40 -05:00
Martin Duhem 37037357a3
Fix `help` command arguments parsing
Previously, some additional code was used to parse the arguments to the
`help` command and ensure that the remaining commands were consistent
with the desired state of sbt.

While this code worked well in sbt 1.x, and was helpful in getting `sbt
help new` to work as expected, this does not work in sbt 2, and is
actually not required.

This patch removes the additional code, which fixes the `help` command
in sbt.
2025-12-18 17:49:32 +01:00
Eugene Yokota e6492b771e [2.x] fix: Replace Scala version with u when crossPaths is false
**Problem**
sbt 2.x uses crossTarget by default, but it contains Scala version
even when crossPaths is false.

**Solution**
This replaces it with the letter "u" for unspecified.
2025-12-18 00:00:11 -05:00