Closed kentcdodds closed 3 weeks ago
still looking ....
some info:
this line runs after the test process killed: GET http://localhost:5639/test?name=playground&v=1
https://github.com/epicweb-dev/kcdshop/blob/b442096f270962da463d2eb3c949a996f726d6a3/packages/workshop-app/app/routes/test.tsx#L195-L197
when the loader run this https://github.com/epicweb-dev/kcdshop/blob/b442096f270962da463d2eb3c949a996f726d6a3/packages/workshop-app/app/routes/test.tsx#L76
remix crashes https://github.com/remix-run/remix/blob/8ec97222cd46f8a716712e69d640f2fb4efacfb2/packages/remix-react/data.ts#L58-L68
maybe we can use abortController
to abort the test, then clean testProcess
set, and on the test loader return early without calling eventStream
Ah yes, that does make sense
there is some race condition
the loader start the fetch for http://localhost:5639/test?name=playground&v=1
before the test process killed
I did not now how to stop both the loader eventStream
and the test process without crashing remix
this is still an issue with remix 1.18
Fixed. It was something weird with execa. Switch to child_process and it's working fine now.
If you run the tests and stop them before they're done, that somehow kills the app server. I have no idea why.