Skip to content
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

Migrate to new Scala.js Linker API #1685

Closed
wants to merge 2 commits into from

Conversation

shishkin
Copy link
Contributor

Scala.js linker now supports multiple top-level modules: https://www.scala-js.org/doc/project/module.html.

Currently, Mill fails to link those setup as it is using deprecated Linker API. See #1684.

This PR is my attempt to migrate to the new API that solves the issue.

As I'm new to the project, please let me know what else might be impacted by the change. I've managed to get my original issue with fastOpt resolved. Still need to test the test command as well.

@lefou lefou requested a review from lolgab January 19, 2022 21:02
@shishkin
Copy link
Contributor Author

As expected, I broke the test runner in Scala.js. For some reason TestAdapter is failing to find the framework.

java.lang.RuntimeException: Failed to get framework
    mill.scalajslib.worker.ScalaJSWorkerImpl.$anonfun$getFramework$2(ScalaJSWorkerImpl.scala:171)
    scala.Option.getOrElse(Option.scala:201)
    mill.scalajslib.worker.ScalaJSWorkerImpl.getFramework(ScalaJSWorkerImpl.scala:171)
    mill.scalajslib.ScalaJSWorker.getFramework(ScalaJSWorkerApi.scala:68)
    mill.scalajslib.TestScalaJSModule.$anonfun$testTask$1(ScalaJSModule.scala:259)
    mill.define.Task$TraverseCtx.evaluate(Task.scala:376)
1 targets failed

Will try to debug further.

@shishkin
Copy link
Contributor Author

Sorry, I'm not able to figure out the tester part without knowledge of scalajs internals. Would somebody be able to provide some direction?

@lefou lefou added the rebase-needed This pull request needs a git rebase before a merge is possible label Jan 29, 2022
@lefou lefou marked this pull request as draft January 29, 2022 09:48
@shishkin
Copy link
Contributor Author

Fixed in #1714 instead.

@shishkin shishkin closed this Jan 30, 2022
@lefou
Copy link
Member

lefou commented Jan 30, 2022

Although we don't merged it, thank you anyway! Your contribution is appreciated.

@lefou lefou removed the rebase-needed This pull request needs a git rebase before a merge is possible label Jan 30, 2022
@shishkin
Copy link
Contributor Author

Thank you 👍

@lolgab
Copy link
Member

lolgab commented May 9, 2022

@shishkin This is now fully solved in Mill 0.10.4

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.

3 participants