Skip to content

Conversation

hamzaremmal
Copy link
Member

@hamzaremmal hamzaremmal commented Aug 15, 2025

This PR configures the scripted tests (sbt-test) to be run using the new stdlib.
This PR should fail at the moment as we do not have the scaladoc artifacts yet in the build.

@hamzaremmal hamzaremmal self-assigned this Aug 15, 2025
hamzaremmal added a commit that referenced this pull request Aug 15, 2025
…nstead of `semver-spec` (#23753)

In some scenarios, specifically in cross compilation projects, sbt will
complain that `scala-library:2.13.x` and `scala-library:3.x.y` might be
imcompatible, as they are both declared `semver-spec`. See en example
here:
```scala
[error] (update) found version conflict(s) in library dependencies; some are suspected to be binary incompatible:
[error] 
[error] 	* org.scala-lang:scala-library:3.8.0-RC1-bin-SNAPSHOT (semver-spec) is selected over 2.13.0
[error] 	    +- org.scala-lang:scala3-library_3:3.8.0-RC1-bin-SNAPSHOT (depends on 3.8.0-RC1-bin-SNAPSHOT)
[error] 	    +- org.scala-lang.modules:scala-xml_2.13:1.2.0        (depends on 2.13.0)
```

In this PR, we change the version scheme of both `scala-library` and
`scalajs-scalalib_2.13` to `always` so that the transition between the
old stdlib structure and the new one stay invisible to the users.
In the future, when we break binary compatibility (meaning Scala 4), we
can revert this PR and have artifacts labeled with `semver-spec` as it
will be exactly that scheme.

---

The correctness was validated in #23748 locally.

[skip ci]
@hamzaremmal hamzaremmal force-pushed the new-sbt-test branch 2 times, most recently from 0341c3f to 9a24c0a Compare September 15, 2025 14:54
@hamzaremmal hamzaremmal force-pushed the new-sbt-test branch 2 times, most recently from e717cd2 to 1a0d946 Compare October 7, 2025 12:35
Comment on lines -65 to -67
- name: Generate documentation for example project using dotty-sbt
run: ./project/scripts/sbt "sbt-test/scripted sbt-dotty/scaladoc"

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We will be running these alongside all the other scripted tests anyways, no need to run them twice.

@hamzaremmal hamzaremmal marked this pull request as ready for review October 7, 2025 12:39
@sjrd
Copy link
Member

sjrd commented Oct 7, 2025

This failed for Scala.js scripted tests. But it's the same error that we fixed with fe7c711, so if we merge #24143 first, we should be able to rebase on top of it to make this PR work.

@hamzaremmal
Copy link
Member Author

This failed for Scala.js scripted tests. But it's the same error that we fixed with fe7c711, so if we merge #24143 first, we should be able to rebase on top of it to make this PR work.

Yes, the test I did locally was on top of #24143.

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.

2 participants