-
Notifications
You must be signed in to change notification settings - Fork 75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update sbt-scalajs, scalajs-compiler, ... to 1.8.0 #734
Conversation
452e93e
to
9a1b632
Compare
object TestContext { | ||
// Why is this context distinct from the global execution context that Scala provides | ||
// out of the box? | ||
// In short, because browsers / JS are _very different_ from the JVM. Copying / pasting | ||
// from the macrotask executor's explanation of why that library exists in its README: | ||
// (https://github.com/scala-js/scala-js-macrotask-executor/tree/v1.0.0) | ||
// | ||
// "Unless you have some very, very specific and unusual requirements, this is the optimal | ||
// ExecutionContext implementation for use in any Scala.js project. | ||
// If you're using ExecutionContext and not using this project, you likely have some serious | ||
// bugs and/or performance issues waiting to be discovered." | ||
// | ||
// This library goes through the trouble of providing this special execution context and | ||
// reorganizing just to provide that context in tests to make it more obvious for downstream | ||
// JS consumers what to fix / how to make a pretty menacing warning go away. | ||
|
||
val context: ExecutionContext = Implicits.global | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the meat of the change -- you can see the README for more details. Scala.js 1.8.0 introduced warnings about using Scala's global execution context: https://www.scala-js.org/news/2021/12/10/announcing-scalajs-1.8.0/
This happened only in tests but still required repair. The warning could have been suppressed, but then downstream consumers of the JS lib would have had to figure it out on their own. This seems better, though the cost is pretty high -- CrossProject.Pure
was no longer sufficient since we know have platform-specific code.
Updates
from 1.7.1 to 1.8.0.
GitHub Release Notes - Version Diff
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.
Configure Scala Steward for your repository with a
.scala-steward.conf
file.Have a fantastic day writing Scala!
Files still referring to the old version number
The following files still refer to the old version number (1.7.1).
You might want to review and update them manually.
Ignore future updates
Add this to your
.scala-steward.conf
file to ignore future updates of this dependency:labels: library-update, early-semver-minor, semver-spec-minor, old-version-remains