Open bpholt opened 1 year ago
Hmm, no, that seems odd. Any chance you can link to the build?
INFO: my Scala cross versions are specified as:
inThisBuild(List(
...
crossScalaVersions := Seq(Scala213, Scala212, Scala3),
...
)
Which I believe should be equivalent to what you had: it works fine on RC9
.
Any chance you can link to the build?
Unfortunately this is an internal library so I can't share the build. I'll see if I can minimize.
inThisBuild(List( ... crossScalaVersions := Seq(Scala213, Scala212, Scala3), ... )
FWIW, I was under the impression that the inThisBuild
macro has some subtle differences from the ThisBuild
scope, so we've been moving things to use the scope directly. But in any event, in this build, I get the same NoSuchElementException
using
inThisBuild(List(
crossScalaVersions := Seq(Scala_2_12, Scala_2_13)
))
(albeit with a lot of other settings still set using the scope directly)
@armanbilge I was able to minimize; check out this gist. tl;dr, it looks like it was caused by the root project explicitly setting crossScalaVersions := Seq.empty
. (It did that to suppress publishing in the root project; I've since switched it to use the NoPublishPlugin instead.)
Using sbt-typelevel-settings v0.5.0-RC9, is it expected that using
will result in this error on load?
Removing
ThisBuild /
makes it work, but it's surprising that it matters:This is the line in question:
https://github.com/typelevel/sbt-typelevel/blob/9309a656f0f3b97dfe2650fb6a8c99362a958fea/settings/src/main/scala/org/typelevel/sbt/TypelevelSettingsPlugin.scala#L49