Commit Graph

12265 Commits

Author SHA1 Message Date
Eugene Yokota 12d2cc8ef1 fix: Use Retry.io for compilation
**Problem**
sbt 1.10.10 still has retry problem with compilation.

**Solution**
Revert the retry logic back to the time when we only retried IOExceptions.
2025-03-16 21:43:01 -04:00
eugene yokota 75536d12a5
Merge pull request #8069 from eed3si9n/wip/update-coursier
[1.x] Update lm-coursier-shaded to 2.1.8
2025-03-16 21:15:22 -04:00
Eugene Yokota 0e1088145a Update lm-coursier-shaded to 2.1.8 2025-03-16 19:53:50 -04:00
eugene yokota 0d4c11b396
Merge pull request #8067 from eed3si9n/wip/fix-warning
[1.x] fix: Fix SIP-51 message
2025-03-16 15:37:01 -04:00
Eugene Yokota bd7bf73de5 fix: Fix SIP-51 message
**Problem**
The error message uses name, which may not match the actual project id
that the user can type into the shell.

**Solution**
Use displayBuildRelative to calculate the proper subproject id.
2025-03-16 14:58:23 -04:00
eugene yokota 9c08aea5fc
Merge pull request #8066 from eed3si9n/wip/v
[1.x] fix: Avoid creating target on sbt -V
2025-03-16 02:29:15 -04:00
Eugene Yokota 89ff2440ef fix: Avoid creating target on sbt -V
**Problem**
sbt -V tries to show both the sbt version and the runner version,
and ends up creating target directory even on a non-sbt directory.

**Solution**
If the current directory doesn't have a build, just display the runner version.
2025-03-16 02:08:33 -04:00
eugene yokota 78bffa22b6
Merge pull request #8057 from eed3si9n/wip/shutdown
[1.x] Shortcut sbtn shutdown
2025-03-05 22:06:50 -05:00
Eugene Yokota 9d4cc80a80 Shortcut sbtn shutdown
**Problem**
WHen portfile is not found, sbtn will try to start the server
even when the desired command is shutdown.

**Solution**
When the command is just shutdown, don't start the server.
2025-03-05 02:27:46 -05:00
Eugene Yokota 70a8ee4fb4 sbt 1.10.10 2025-03-04 01:01:15 -05:00
eugene yokota ce38f0a37d
Merge pull request #8054 from eed3si9n/wip/retry
[1.x] Skip retry on CompileCancelled
2025-03-03 22:57:07 -05:00
Eugene Yokota 946b54c858 Skip retry on CompileCancelled
**Problem**
When compilation fails, it's retrying 10 times
since Retry now retries on non-IOExceptions.

**Solution**
This adds CompileFailed to excluded exception list.
2025-03-03 22:19:22 -05:00
Eugene Yokota a3a72b3245 sbt 1.10.9 2025-03-03 13:06:40 -05:00
eugene yokota d3ea4c5771
Merge pull request #8052 from eed3si9n/wip/bump-zinc
Zinc 1.10.8 + sbtn 1.10.8
2025-03-03 12:37:14 -05:00
Eugene Yokota 290431bfc5 Zinc 1.10.8 + sbtn 1.10.8 2025-03-03 12:22:09 -05:00
eugene yokota 0c1fd9aff7
Merge pull request #8051 from eed3si9n/wip/revert-run-switching
[1.x] Revert run switching on 1.x
2025-03-03 11:23:33 -05:00
Eugene Yokota 5d5fe21ec5 Revert run switching on 1.x
**Problem**
client-side run apparently won't work for Scala.JS,
so forcing sbtn users to client-side run will break the Scala.JS users.

**Solution**
This reverts the client-side run on sbt 1.x, while retaining the
mechanism for sbt 2.x usages via sbtn.
Now, if `run / connectInput := true` is true, stdout will not display on sbtn.
2025-03-03 04:59:36 -05:00
eugene yokota f43030a2c2
Merge pull request #8050 from eed3si9n/wip/bump-lm
[1.x] lm 1.10.4
2025-03-03 03:05:53 -05:00
Eugene Yokota a18ed19cbc fix: Use JDK path, not JRE path
**Problem**
There are a few places where javaHome or java path is set,
using java.home system property. The problem is that it points to JRE,
not JDK, so it would break on Java compilation etc.

**Solution**
If the path ends with jre, go up one directory.
2025-03-03 02:31:44 -05:00
Eugene Yokota 444362c735 lm 1.10.4 2025-03-02 22:30:45 -05:00
eugene yokota 3dc4317d54
Merge pull request #8049 from eed3si9n/wip/sbt-init
[1.x] fix: sbt init
2025-03-02 22:08:06 -05:00
eugene yokota bdaf1d9d32
Merge pull request #8040 from eed3si9n/wip/sandbox
[1.x] Implement client-side run
2025-03-02 22:07:46 -05:00
Eugene Yokota 7409de3c40 fix: sbt init
**Problem**
`sbt init` no longer works because of --allow-empty check.

**Solution**
Skip allow empty check for sbt init.
2025-03-02 21:02:55 -05:00
Eugene Yokota 67265638c6 Implement client-side run
**Problem**
`run` task blocks the server, but during the run the server is just
waiting for the built program to finish.

**Solution**
This implements client-side run where the server creates a sandbox
environment, and sends the information to the client,
and the client forks a new JVM to perform the run.
2025-03-02 20:45:04 -05:00
eugene yokota 003e54936f
Merge pull request #8048 from eed3si9n/wip/stdout
[1.x] Fix stdout freshness issue
2025-03-01 22:11:14 -08:00
Eugene Yokota 7ce978a5f2 Fix stdout freshness issue
**Problem**
When ForkOptions outputStrategy is None, Run code currently
tries to use LoggedOutput, which buffers the output when
connectInput is true, which effectively breaks the experience.

**Solution**
This stops falling back to LoggedOutput when connectInput is true.
2025-03-02 00:31:34 -05:00
eugene yokota 1d16ca9510
Merge pull request #8038 from mehdignu/fix-sbtn-arch-logging
Fix incorrect sbt architecture logging on MacOS arm64
2025-02-15 22:33:36 -05:00
mehdi a266e10556 move arch detection into darwin block 2025-02-15 18:27:34 +01:00
eugene yokota da54265119
Merge pull request #8035 from eed3si9n/wip/refactor-sbtn
[1.x] refactor: Refactor response handler
2025-02-09 19:32:12 -05:00
Eugene Yokota a75e847a08 refactor: Refactor response handler
**Problem**
The sbtn response handling code is relatively stragightforward,
but it's a bit messy.

**Solution**
This cleans it up a bit, similar to the style used by Unfiltered
back then (not sure how Unfiltered plans are written nowadays) by
expressing each event handling as a partial function, and composing them
together using `orElse`.
2025-02-09 18:17:02 -05:00
Eugene Yokota 06acd261d5 Scala 2.13.16 2025-02-09 18:17:02 -05:00
eugene yokota c99a269bfb
Merge pull request #8032 from unkarjedy/1.10.x 2025-02-04 22:13:38 -05:00
Dmitrii Naumenko a7d862a08b detect user-specific jdk installations on macOs (fixes #8031)
User-specific JDKs are installed, for example, by IntelliJ IDEA
2025-02-04 18:11:40 +01:00
eugene yokota 58be9438f8
Merge pull request #8021 from eed3si9n/bport/8019
[1.x] Make timing outputs consistently show hours and hint at time format
2025-01-29 04:44:25 -05:00
Josh Soref 2ee5eb7fa7 Make timing outputs consistently show hours and hint at time format
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-01-29 04:20:37 -05:00
eugene yokota 4ae14cf689
Merge pull request #8020 from eed3si9n/wip/tid 2025-01-28 09:33:05 -05:00
Eugene Yokota 55b1fdeddb fix: Fix Chrome tracing file
**Problem**
We changed the content of Chrome tracing file incorrectly
and renamed tid to tname.

**Solution**
1. This renames tname back to to tid.
2. To retain the fix to avoid Thread#getId, this calls
   either the JDK 8 way or the JDK 19 way reflectively.
2025-01-28 04:11:36 -05:00
eugene yokota a1603d9952
Merge pull request #8012 from lrytz/sip51-warn
Add setting to allow demoting the SIP-51 build failure
2025-01-20 18:14:21 -05:00
Lukas Rytz e46843bfd9 Add setting to allow demoting the SIP-51 build failure
Add a `allowUnsafeScalaLibUpgrade` setting (default is `false`) to
demote the SIP-51 build failure to a warning.

If the scalaVersion is 2.13.12 but some dependency pulls in
scala-library 2.13.13, the compiler will stay at 2.13.12, but
the dependency classpath will contain scala-library 2.13.13.

This usually works, the compiler can run fine with a newer
scala-library on its dependency classpath.
Macro expansion may fail, if the macro uses some library
class / method that doesn't exist in the old version.
The macro itself is loaded from the dependency classpath
into the class loader running the compiler, where the older
Scala library is on the runtime classpath.
Using the Scala REPL in sbt may also fail in a similar fashion.
2025-01-20 10:00:13 +01:00
eugene yokota d99163b945
Merge pull request #8005 from dwickern/fix-npe
Fix race condition in NetworkChannel
2025-01-11 22:26:21 -05:00
Derek Wickern f0afda3dd0 make NetworkChannel#thread private 2025-01-11 13:08:18 -08:00
Derek Wickern a13bfd3ef9 fix race condition in NetworkChannel 2025-01-11 12:46:35 -08:00
eugene yokota fde334bdd6
Merge pull request #7983 from Friendseeker/lazy-previous-compile
[1.x] Avoid upstream compilation when calling `previousCompile`
2024-12-30 23:38:14 -05:00
friendseeker c834f500b9
Add comment 2024-12-30 19:30:15 -08:00
Friendseeker 1a8fa65af3 Avoid upstream compilation when calling previousCompile 2024-12-30 17:55:42 -08:00
adpi2 011c7083ad
Merge pull request #7913 from Friendseeker/sbt-7510
[1.x] Implement `jvmBuildTarget` for `workspace/buildTargets`
2024-12-30 09:06:53 +01:00
eugene yokota 038d9b28e4
Merge pull request #7969 from Friendseeker/clean-zinc-cache
[1.x] Clear Zinc Analysis Cache during `Compile / clean`, `Test / clean`
2024-12-28 23:57:59 -05:00
Friendseeker 13373415b3 Fix CI 2024-12-26 18:43:04 -08:00
friendseeker e23419efed Clean Zinc Cache for 'Compile / clean', 'Test / clean' 2024-12-26 15:37:33 -08:00
Friendseeker 838eee97cd Fix CI 2024-12-26 15:05:00 -08:00