-
Notifications
You must be signed in to change notification settings - Fork 3
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
Test case crash with unknow problem. #49
Comments
wsl2 [info] Fast optimizing /mnt/e/pro/workspace/simple-nat/modules/main/simple-adt/core/js/target/scala-2.13/simple-adt-core-test-fastopt
qt.qpa.xcb: could not connect to display
qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.
Available platform plugins are: eglfs, linuxfb, minimal, minimalegl, offscreen, vnc, xcb.
PhantomJS has crashed. Please read the bug reporting guide at
<http://phantomjs.org/bug-reporting.html> and file a bug report.
[error] stack trace is suppressed; run last adt-coreJS / Test / loadedTestFrameworks for the full output
[error] (adt-coreJS / Test / loadedTestFrameworks) org.scalajs.testing.common.RPCCore$ClosedException: org.scalajs.testing.adapter.JSEnvRPC$RunTerminatedException
[error] Total time: 94 s (01:34), completed Sep 30, 2022, 10:26:45 AM
sbt:simple-nat> last adt-coreJS / Test / loadedTestFrameworks
[debug] PhantomJS WS Jetty: INFO: jetty-8.1.16.v20140903 WrappedArray()
[debug] PhantomJS WS Jetty: INFO: Started {} WrappedArray(SelectChannelConnector@localhost:34907)
[debug] PhantomJS using webpage launcher at: /tmp/phantomjs-launcher-webpage17731834358584063541.html
[debug] PhantomJS using launcher at: /tmp/phantomjs-launcher16382325301618177454.js
[debug] Starting process: phantomjs /tmp/phantomjs-launcher16382325301618177454.js
[error] org.scalajs.testing.common.RPCCore$ClosedException: org.scalajs.testing.adapter.JSEnvRPC$RunTerminatedException
[error] at org.scalajs.testing.common.RPCCore.helpClose(RPCCore.scala:223)
[error] at org.scalajs.testing.common.RPCCore.close(RPCCore.scala:215)
[error] at org.scalajs.testing.adapter.JSEnvRPC.close(JSEnvRPC.scala:69)
[error] at org.scalajs.testing.adapter.JSEnvRPC.$anonfun$new$1(JSEnvRPC.scala:60)
[error] at org.scalajs.testing.adapter.JSEnvRPC.$anonfun$new$1$adapted(JSEnvRPC.scala:60)
[error] at scala.concurrent.impl.CallbackRunnable.run(Promise.scala:64)
[error] at java.base/java.util.concurrent.ForkJoinTask$RunnableExecuteAction.exec(ForkJoinTask.java:1426)
[error] at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:290)
[error] at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1020)
[error] at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1656)
[error] at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1594)
[error] at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:183)
[error] Caused by: org.scalajs.testing.adapter.JSEnvRPC$RunTerminatedException
[error] at org.scalajs.testing.adapter.JSEnvRPC.$anonfun$new$1(JSEnvRPC.scala:60)
[error] at org.scalajs.testing.adapter.JSEnvRPC.$anonfun$new$1$adapted(JSEnvRPC.scala:60)
[error] at scala.concurrent.impl.CallbackRunnable.run(Promise.scala:64)
[error] at java.base/java.util.concurrent.ForkJoinTask$RunnableExecuteAction.exec(ForkJoinTask.java:1426)
[error] at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:290)
[error] at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1020)
[error] at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1656)
[error] at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1594)
[error] at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:183)
[error] Caused by: org.scalajs.jsenv.ExternalJSRun$NonZeroExitException: exited with code 134
[error] at org.scalajs.jsenv.ExternalJSRun$$anon$1.run(ExternalJSRun.scala:200)
[error] (adt-coreJS / Test / loadedTestFrameworks) org.scalajs.testing.common.RPCCore$ClosedException: org.scalajs.testing.adapter.JSEnvRPC$RunTerminatedException
sbt:simple-nat> |
windows cmd [warn] one warning found
[info] Fast optimizing E:\pro\workspace\simple-nat\modules\main\simple-adt\core\js\target\scala-2.13\simple-adt-core-test-fastopt
[error] stack trace is suppressed; run last adt-coreJS / Test / loadedTestFrameworks for the full output
[error] (adt-coreJS / Test / loadedTestFrameworks) org.scalajs.testing.common.RPCCore$ClosedException: org.scalajs.testing.adapter.JSEnvRPC$RunTerminatedException
[error] Total time: 36 s, completed 2022骞?鏈?0鏃?涓婂崍10:34:34
sbt:simple-nat>
sbt:simple-nat>
sbt:simple-nat>
sbt:simple-nat>
sbt:simple-nat>
sbt:simple-nat>
sbt:simple-nat> last adt-coreJS / Test / loadedTestFrameworks
[debug] PhantomJS WS Jetty: INFO: jetty-8.1.16.v20140903 WrappedArray()
[debug] PhantomJS WS Jetty: INFO: Started {} WrappedArray(SelectChannelConnector@localhost:61650)
[error] org.scalajs.testing.common.RPCCore$ClosedException: org.scalajs.testing.adapter.JSEnvRPC$RunTerminatedException
[error] at org.scalajs.testing.common.RPCCore.helpClose(RPCCore.scala:223)
[error] at org.scalajs.testing.common.RPCCore.call(RPCCore.scala:164)
[error] at org.scalajs.testing.adapter.TestAdapter.loadFrameworks(TestAdapter.scala:57)
[error] at org.scalajs.sbtplugin.ScalaJSPluginInternal$.$anonfun$scalaJSTestSettings$6(ScalaJSPluginInternal.scala:704)
[error] at org.scalajs.sbtplugin.ScalaJSPluginInternal$.enhanceNotInstalledException(ScalaJSPluginInternal.scala:104)
[error] at org.scalajs.sbtplugin.ScalaJSPluginInternal$.$anonfun$scalaJSTestSettings$4(ScalaJSPluginInternal.scala:704)
[error] at scala.Function1.$anonfun$compose$1(Function1.scala:49)
[error] at sbt.internal.util.$tilde$greater.$anonfun$$u2219$1(TypeFunctions.scala:62)
[error] at sbt.std.Transform$$anon$4.work(Transform.scala:68)
[error] at sbt.Execute.$anonfun$submit$2(Execute.scala:282)
[error] at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:23)
[error] at sbt.Execute.work(Execute.scala:291)
[error] at sbt.Execute.$anonfun$submit$1(Execute.scala:282)
[error] at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:265)
[error] at sbt.CompletionService$$anon$2.call(CompletionService.scala:64)
[error] at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
[error] at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
[error] at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
[error] at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
[error] at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
[error] at java.base/java.lang.Thread.run(Thread.java:834)
[error] Caused by: org.scalajs.testing.adapter.JSEnvRPC$RunTerminatedException
[error] at org.scalajs.testing.adapter.JSEnvRPC.$anonfun$new$1(JSEnvRPC.scala:60)
[error] at org.scalajs.testing.adapter.JSEnvRPC.$anonfun$new$1$adapted(JSEnvRPC.scala:60)
[error] at scala.concurrent.impl.CallbackRunnable.run(Promise.scala:64)
[error] at java.base/java.util.concurrent.ForkJoinTask$RunnableExecuteAction.exec(ForkJoinTask.java:1426)
[error] at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:290)
[error] at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1020)
[error] at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1656)
[error] at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1594)
[error] at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:177)
[error] Caused by: java.nio.file.FileSystemException: E:\pro\workspace\simple-nat\modules\main\simple-adt\core\js\target\scala-2.13\simple-adt-core-test-fastopt: Unable to determine if root directory exists
[error] at java.base/java.nio.file.Files.createDirectories(Files.java:771)
[error] at org.scalajs.jsenv.phantomjs.PhantomJSEnv.$anonfun$writeWebpageLauncher$1(PhantomJSEnv.scala:219)
[error] at scala.collection.immutable.List.flatMap(List.scala:366)
[error] at org.scalajs.jsenv.phantomjs.PhantomJSEnv.writeWebpageLauncher(PhantomJSEnv.scala:209)
[error] at org.scalajs.jsenv.phantomjs.PhantomJSEnv.createTmpWebpage(PhantomJSEnv.scala:189)
[error] at org.scalajs.jsenv.phantomjs.PhantomJSEnv.createTmpLauncherFile(PhantomJSEnv.scala:126)
[error] at org.scalajs.jsenv.phantomjs.PhantomJSEnv.internalStart(PhantomJSEnv.scala:58)
[error] at org.scalajs.jsenv.phantomjs.PhantomJSEnv.$anonfun$startWithCom$1(PhantomJSEnv.scala:41)
[error] at org.scalajs.jsenv.phantomjs.ComRun.org$scalajs$jsenv$phantomjs$ComRun$$onServerRunning(ComRun.scala:73)
[error] at org.scalajs.jsenv.phantomjs.ComRun$$anon$1.onRunning(ComRun.scala:51)
[error] at org.scalajs.jsenv.phantomjs.JettyWebsocketManager$$anon$2.lifeCycleStarted(JettyWebsocketManager.scala:49)
[error] at org.eclipse.jetty.util.component.AbstractLifeCycle.setStarted(AbstractLifeCycle.java:174)
[error] at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:65)
[error] at org.scalajs.jsenv.phantomjs.JettyWebsocketManager.start(JettyWebsocketManager.scala:121)
[error] at org.scalajs.jsenv.phantomjs.ComRun.<init>(ComRun.scala:66)
[error] at org.scalajs.jsenv.phantomjs.ComRun$.start(ComRun.scala:267)
[error] at org.scalajs.jsenv.phantomjs.PhantomJSEnv.startWithCom(PhantomJSEnv.scala:40)
[error] at org.scalajs.testing.adapter.JSEnvRPC.<init>(JSEnvRPC.scala:46)
[error] at org.scalajs.testing.adapter.TestAdapter.startManagedRunner(TestAdapter.scala:128)
[error] at org.scalajs.testing.adapter.TestAdapter.$anonfun$getRunnerForThread$1(TestAdapter.scala:120)
[error] at scala.collection.concurrent.TrieMap.getOrElseUpdate(TrieMap.scala:895)
[error] at org.scalajs.testing.adapter.TestAdapter.getRunnerForThread(TestAdapter.scala:120)
[error] at org.scalajs.testing.adapter.TestAdapter.loadFrameworks(TestAdapter.scala:56)
[error] at org.scalajs.sbtplugin.ScalaJSPluginInternal$.$anonfun$scalaJSTestSettings$6(ScalaJSPluginInternal.scala:704)
[error] at org.scalajs.sbtplugin.ScalaJSPluginInternal$.enhanceNotInstalledException(ScalaJSPluginInternal.scala:104)
[error] at org.scalajs.sbtplugin.ScalaJSPluginInternal$.$anonfun$scalaJSTestSettings$4(ScalaJSPluginInternal.scala:704)
[error] at scala.Function1.$anonfun$compose$1(Function1.scala:49)
[error] at sbt.internal.util.$tilde$greater.$anonfun$$u2219$1(TypeFunctions.scala:62)
[error] at sbt.std.Transform$$anon$4.work(Transform.scala:68)
[error] at sbt.Execute.$anonfun$submit$2(Execute.scala:282)
[error] at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:23)
[error] at sbt.Execute.work(Execute.scala:291)
[error] at sbt.Execute.$anonfun$submit$1(Execute.scala:282)
[error] at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:265)
[error] at sbt.CompletionService$$anon$2.call(CompletionService.scala:64)
[error] at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
[error] at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
[error] at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
[error] at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
[error] at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
[error] at java.base/java.lang.Thread.run(Thread.java:834)
[error] (adt-coreJS / Test / loadedTestFrameworks) org.scalajs.testing.common.RPCCore$ClosedException: org.scalajs.testing.adapter.JSEnvRPC$RunTerminatedException
sbt:simple-nat> |
Can not solve it by |
We do not maintain this project anymore. PhantomJS itself has been EOL for years. Keep using it at your own risk. |
Oh, I see. @sjrd Then I can understand why this happens. By the way, are there any js environments that can run only depending on the jvm? E.g. nashorn. Just not depending environment out of the |
What I need is, now I used to shared the project with my friend. Copy the environment is not so friendly for my friend because of the limited code learning. // sbt.bat
java -jar "./sbt-launcher.jar" in Windows run // J2V8 & Javet link
https://github.com/eclipsesource/J2V8
https://github.com/caoccao/Javet
https://github.com/caoccao/Javet/releases?q=j2v8&expanded=true |
I don't think there currently is one implemented. Early versions of Scala.js relied on Rhino (a Nashorn predecessor). However, Rhino struggled with the size of the code Scala.js generated and installing Node.js seemed to be not an issue for most users. So that's the default now. It is very well possible that nowadays, Nashorn will deal just fine with the Scala.js generated code (it's much smaller now, I'd also expect Nashorn to be better). However, I don't know of any JSEnv implementation for that. (if you want to give it a shot, I'm happy to give you pointers). |
@gzm0 The J2V8 and Javet is a good choice for the full jvm environment. But |
If implement a |
Update |
Use node current and close. |
Environment:
t
(alias for+mainProjects/test
) or a simple test command:adt-coreJS/test
This project build failed for
PhantomJSEnv
with unknown reason. Have a test in win and wsl2. The error code will be different in Windows and wsl2.The text was updated successfully, but these errors were encountered: