question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Bad interactions in JSDOMNodeJSEnv error handling with React.js dev mode on jsdom v10+

See original GitHub issue

I can’t get a run of utest 0.6.4 or even 0.6.5 with the opcode change, of scalajs-react tests to complete with SJS 0.6.25. I constantly one of the following errors which kills all subsequent tests. I’ve had to downgrade SJS to 0.6.24

org.scalajs.testcommon.RPCCore$ClosedException
	at org.scalajs.testcommon.RPCCore.helpClose(RPCCore.scala:193)
	at org.scalajs.testcommon.RPCCore.close(RPCCore.scala:185)
	at org.scalajs.testadapter.ComJSEnvRPC.org$scalajs$testadapter$ComJSEnvRPC$$super$close(ComJSEnvRPC.scala:50)
	at org.scalajs.testadapter.ComJSEnvRPC$$anon$1.run(ComJSEnvRPC.scala:50)
Caused by: org.scalajs.jsenv.ComJSEnv$ComClosedException: JSCom has been closed
	at org.scalajs.jsenv.nodejs.AbstractNodeJSEnv$NodeComJSRunner$class.receive(AbstractNodeJSEnv.scala:284)
	at org.scalajs.jsenv.nodejs.JSDOMNodeJSEnv$ComDOMNodeRunner.receive(JSDOMNodeJSEnv.scala:62)
	at org.scalajs.jsenv.ComJSRunner$class.receive(ComJSRunner.scala:15)
	at org.scalajs.jsenv.nodejs.JSDOMNodeJSEnv$ComDOMNodeRunner.receive(JSDOMNodeJSEnv.scala:62)
	at org.scalajs.testadapter.ComJSEnvRPC$$anon$1.run(ComJSEnvRPC.scala:31)
Caused by: java.io.EOFException
	at java.io.DataInputStream.readInt(DataInputStream.java:392)
	at org.scalajs.jsenv.nodejs.AbstractNodeJSEnv$NodeComJSRunner$class.receive(AbstractNodeJSEnv.scala:274)
	at org.scalajs.jsenv.nodejs.JSDOMNodeJSEnv$ComDOMNodeRunner.receive(JSDOMNodeJSEnv.scala:62)
	at org.scalajs.jsenv.ComJSRunner$class.receive(ComJSRunner.scala:15)
	at org.scalajs.jsenv.nodejs.JSDOMNodeJSEnv$ComDOMNodeRunner.receive(JSDOMNodeJSEnv.scala:62)
	at org.scalajs.testadapter.ComJSEnvRPC$$anon$1.run(ComJSEnvRPC.scala:31)

or

org.scalajs.testcommon.RPCCore$ClosedException
	at org.scalajs.testcommon.RPCCore.helpClose(RPCCore.scala:193)
	at org.scalajs.testcommon.RPCCore.close(RPCCore.scala:185)
	at org.scalajs.testadapter.ComJSEnvRPC.org$scalajs$testadapter$ComJSEnvRPC$$super$close(ComJSEnvRPC.scala:50)
	at org.scalajs.testadapter.ComJSEnvRPC$$anon$1.run(ComJSEnvRPC.scala:50)
Caused by: org.scalajs.jsenv.ComJSEnv$ComClosedException: JSCom has been closed
	at org.scalajs.jsenv.nodejs.AbstractNodeJSEnv$NodeComJSRunner$class.receive(AbstractNodeJSEnv.scala:284)
	at org.scalajs.jsenv.nodejs.JSDOMNodeJSEnv$ComDOMNodeRunner.receive(JSDOMNodeJSEnv.scala:62)
	at org.scalajs.jsenv.ComJSRunner$class.receive(ComJSRunner.scala:15)
	at org.scalajs.jsenv.nodejs.JSDOMNodeJSEnv$ComDOMNodeRunner.receive(JSDOMNodeJSEnv.scala:62)
	at org.scalajs.testadapter.ComJSEnvRPC$$anon$1.run(ComJSEnvRPC.scala:31)
Caused by: java.io.EOFException
	at java.io.DataInputStream.readInt(DataInputStream.java:392)
	at org.scalajs.jsenv.nodejs.AbstractNodeJSEnv$NodeComJSRunner$class.receive(AbstractNodeJSEnv.scala:274)
	at org.scalajs.jsenv.nodejs.JSDOMNodeJSEnv$ComDOMNodeRunner.receive(JSDOMNodeJSEnv.scala:62)
	at org.scalajs.jsenv.ComJSRunner$class.receive(ComJSRunner.scala:15)
	at org.scalajs.jsenv.nodejs.JSDOMNodeJSEnv$ComDOMNodeRunner.receive(JSDOMNodeJSEnv.scala:62)
	at org.scalajs.testadapter.ComJSEnvRPC$$anon$1.run(ComJSEnvRPC.scala:31)

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:16 (14 by maintainers)

github_iconTop GitHub Comments

1reaction
sjrdcommented, May 11, 2020

Fixed in f4ecc893010638fc48aa61e7ec328a255c4838f4.

0reactions
gzm0commented, May 22, 2019

Assigning this tentatively to the 0.6 branch, as JSDomNodeJSEnv is in a separate repo in the 1.0 branch.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error Handling in React 16 – React Blog
As React 16 release is getting closer, we would like to announce a few changes to how React handles JavaScript errors inside components....
Read more >
React error handling with react-error-boundary - LogRocket Blog
Error boundaries were introduced in React 16 as a way to catch and handle JavaScript errors that occur in the UI parts of...
Read more >
Running Tests | Create React App
Filename Conventions​. Jest will look for test files with any of the following popular naming conventions: Files with .js suffix in __tests ...
Read more >
How to turn on/off ReactJS 'development mode'?
js for production, React will display a warning message that you've minified non-production code: Warning: It looks like you're using a minified ...
Read more >
Render Sub-component Error in React.js using Error Boundaries
Creating Error Boundary Component. Error boundaries are normal React components that act as a wrapper to catch the errors from the child ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found