-
Notifications
You must be signed in to change notification settings - Fork 56
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
CTRL-C no longer stops a running program. #419
Comments
I think this is a different issue where the Node program running on Tessel doesn't stop after control+C is pressed. I ran into the same issue once when running a server on Tessel and couldn't run new code because the port was still being used. I had to ssh in and kill the process manually. |
That's not Tessel specific, it's the nightmare EADDRINUSE error. |
Anecdotally, I believe this is just a LAN issue. |
I'm unable to reproduce this issue over USB but it's consistent over LAN. I've spent about an hour trying every possible way to close the SSH connection but I'm thinking it's either an issue with the I've opened a relevant issue on the Worst case, I suppose we can add another command |
Potentially relevant: if I run a command with
Anyone else have an idea how to tell it to stop on SSH connection ending? |
Figured it out from this stack exchange question. By adding |
Fixed by #515. |
I'm experiencing this error on my brand new Tessel 2. Let me know which logs to send your way 😃 I have an app that starts an Express server and I currently get EADDRINUSE every time I run the program the second (or more than second) time. |
@sdaitzman can you share the code you're running that's hitting this issue? Thanks! |
@johnnyman727 I found my issue 😄 I was using https://github.com/rgbkrk/atom-script to run my code. When I CTRL-C'd the panel the logs appeared in, it seems that the program continued running on the Tessel. I think this is an issue with that package, not t2 itself. |
👍 That's a sweet plugin. A little menu for deploying to Tessel in Atom would be awesome too. |
Folks, let's be clear: There are a few ways to avoid this:
process.on("SIGINT", _ => server.close());
var port = process.env.PORT || (function() {
return (Math.random() * (4000 - 3000) + 3000) | 0;
})();
server.listen(port, function () {
var host = os.hostname();
var domain = host.includes('local') ? '' : '.local';
console.log(`http://${host}${domain}:${port}`)
}); |
Control C ends the open process locally, but doesn't terminate the remote process.
The text was updated successfully, but these errors were encountered: