Skip to content

improve the error message when Scala version was not detected#73

Merged
eed3si9n merged 1 commit intosbt:1.xfrom
eed3si9n:wip/warnings
Aug 19, 2019
Merged

improve the error message when Scala version was not detected#73
eed3si9n merged 1 commit intosbt:1.xfrom
eed3si9n:wip/warnings

Conversation

@eed3si9n
Copy link
Member

@eed3si9n eed3si9n commented Aug 19, 2019

Fixes sbt/sbt#4955

When Scala version is set to auto, and for some reason the resolution is incomplete (it seems to happen at CI more frequently than normal lately), the launcher will print out the following error message.

before

error during sbt execution: No Scala version specified or detected

after

now it will print this instead:

[error] [launcher] error during sbt launcher: sbt/sbt#4955!
[error] [launcher] sbt launcher is unable to detect the Scala version for jline:jline;
[error] [launcher] this likely indicates an incomplete artifact resolution and/or corrupt boot cache (~/.sbt/boot/).
[error] [launcher] the following is the full classpath that was retrieved for jline:jline:
[error] [launcher]  * /tmp/boot/other/jline/jline/2.14.6/jline-2.14.6.jar

When Scala version is set to `auto`, and for some reason the resolution is incomplete (it seems to happen at CI more frequently than normal lately), the launcher will print out the following error message.

## before

```
error during sbt execution: No Scala version specified or detected
```

## after

now it will print this instead:

```
[error] [launcher] error during sbt launcher: sbt/sbt#4955!
[error] [launcher] sbt launcher is unable to detect the Scala version for jline:jline;
[error] [launcher] this likely indicates an incomplete artifact resolution and/or corrupt boot cache (~/.sbt/boot/).
[error] [launcher] the following is the full classpath that was retrieved for jline:jline:
[error] [launcher]  * /tmp/boot/other/jline/jline/2.14.6/jline-2.14.6.jar
```
@eed3si9n eed3si9n merged commit 2e8e1e6 into sbt:1.x Aug 19, 2019
@eed3si9n eed3si9n deleted the wip/warnings branch August 19, 2019 02:18
@masatiito
Copy link

Excuse me. I got the same error messages when in terminal. Would you tell me what should I do?

Mac OSX 10.14.6
sbt 1.5.3

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.

misleading "Error during sbt execution: No Scala version specified or detected"

2 participants