-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
fix: fuels dev
cleanup not killing node
#3038
base: master
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
@@ -233,7 +233,6 @@ export const launchNode = async ({ | |||
} | |||
childState.isDead = true; | |||
|
|||
removeSideffects(); |
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.
Removing this line caused the issue to go away. I suspect that the root cause of the problem is somewhere in the fuels
package because this line didn't cause problems to e.g. launchTestNode
. It might be in the interplay between file watchers registered in the dev
command and this cleanup
function removing the files they're watching, but I couldn't pinpoint the actual root cause. Tried deleting lines I think might be causing it while having this line still on, but to no avail. We can search for the root cause in another issue that's of lesser priority.
The cleanup still happens because of the exit
and error
event listeners registered on the child above.
it( | ||
'cleans up resources on graceful shutdown', | ||
async () => { | ||
using paths = runInit(); |
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.
The using
keyword is great because you don't have to think about where the test might fail so that you run the cleanup
if it does fail there. With using
, the cleanup will happen automatically both when the test finishes as well as when it throws an error.
CodSpeed Performance ReportMerging #3038 will degrade performances by 54.32%Comparing Summary
Benchmarks breakdown
|
fuels dev
withCTRL+C
(SIGINT
) doesn't killfuel-core
node #2889Summary
Checklist